We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

When cells get user-defined format, System.NullReferenceException occurs.

Thread ID:

Created:

Updated:

Platform:

Replies:

92180 Dec 24,2009 09:59 PM Feb 12,2010 07:44 AM ASP.NET Web Forms (Classic) 7
loading
Tags: XlsIO
Daiki Goto
Asked On December 24, 2009 09:59 PM

Hello.

Please tell me why When cells get user-defined format, System.NullReferenceException occurs.

I think maybe because the double-byte characters are used in user-defined, how to read what's not in this case?



XlsIO_test_7715fb07.zip

Manimala P [Syncfusion]
Replied On December 30, 2009 07:43 AM

Hi Daiki,

Thank you for your interest in Syncfusion products.

You can use the following code snippet to resolve the mentioned issue.

DateTime result = DateTime.Parse(sheet.Range["A1"].Value);
textBox1.Text = result.ToShortDateString();

Please let me know if you have any questions.

Regards,
Manimala.

Daiki Goto
Replied On January 11, 2010 08:02 PM

sheet.Range["A1"] <== 'System.NullReferenceException'

Daiki Goto
Replied On January 11, 2010 08:43 PM

I'm using Microsoft Office Japanese version.
This is a user-defined type [m"月"d"日"] occurs if you have specified.

Manimala P [Syncfusion]
Replied On January 12, 2010 05:37 AM

Hi Daiki,

This issue is confirmed as a defect.Please follow up with incident #63206 for more details.

Please let me know if you have any questions.

Regards,
Manimala.

Daiki Goto
Replied On February 7, 2010 08:55 PM

Thanks for the update.
Certainly exception no longer occurs. However, the user-defined format [m "Mon" d "Sun"] If it is, DisplayText is [m Mon d,] and I should be displayed, [m "Mon" d "Sun"] and will appear. (A waste "would be displayed.)

Daiki Goto
Replied On February 7, 2010 08:57 PM

Sorry.Previous post is incorrect.

Thanks for the update.
Certainly exception no longer occurs.
However, the user-defined format [m"月"d"日"] If it is, DisplayText is [m月d日] and I should be displayed, [m"月"d"日"] and will appear. (A waste ["] would be displayed.)

Manimala P [Syncfusion]
Replied On February 12, 2010 07:44 AM

Hi Daiki,

Thanks for the update.Could you please provide me the clear requirements about the date format which you want to display.

Please let us know if you have any other queries.

Regards,
Manimala.

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;