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. (Last updated on : Nov 16th 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Setting a cell value

Thread ID:

Created:

Updated:

Platform:

Replies:

79762 Feb 25,2009 08:38 AM UTC Apr 24,2009 06:49 AM UTC WinForms 4
loading
Tags: XlsIO
Wout de Zeeuw
Asked On February 25, 2009 08:38 AM UTC

Hi,

I want to set a cell value, and it would be handy if there was a property where I could set the value, and it would detect automatically the .NET object type. I.e. I have a bunch of objects, strings, datetimes, integers, and I want to assign them to cells. Now when setting IRange.Value or Value2, XlsIO detects the type based on the format, not based on the .NET type. Could you guys add a property where XlsIO detects the object type and assigns an appropriate cell format? So if I assign a string to a cell, even if it contains a number like "00343", it would detect to use the string format (and not the number format).

Best regards,

Wout


Wout de Zeeuw
Replied On February 25, 2009 09:05 AM UTC

Note that IRange.Value2 doesn't seem to work, even though from the documentation it seems to be the property that should be doing the job.

E.g. if I assign "00123" (string) to IRange.Value2, it gets converted to a number, even though I'd expect it to be a string.

XlsIO version: 7.102.0.21

Thanks,

Wout



Geetha M [Syncfusion]
Replied On February 25, 2009 02:37 PM UTC

Hi Wout,

Thank you for the details.

The issue of Value2 property does not detects object type based on type is suspected to be a defect and has been forwarded to our development team for more analysis. I will update you the status of the same in two days.

Please let me know if you have any questions.

Regards,
Geetha


Wout de Zeeuw
Replied On April 23, 2009 11:46 AM UTC

Hi Geetha,

Any progress on this?

Thanks,

Wout


Geetha M [Syncfusion]
Replied On April 24, 2009 06:49 AM UTC

Hi Wout,

Sorry for the delay in responding you.

As per design, the Value 2 property currently checks for the following data type:

DateTime, TimeSpan, Double and Integer

When a string is passed, the Value property is called and the object is parsed and get the Number value. I have created a Feature Request on this regard and will update you once it gets implemented.

Please let me know if you have any questions.

Regards,
Geetha


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.

Warning Icon 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.Close Icon

;