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.

PercentTextBox - handling null values

Thread ID:

Created:

Updated:

Platform:

Replies:

19194 Sep 20,2004 05:15 PM Sep 27,2004 04:17 PM Windows Forms 5
loading
Tags: Tools
Administrator [Syncfusion]
Asked On September 20, 2004 05:15 PM

I''m trying to figure out how to get the PercentTextBox to handle null values from my dataset. If I create a databinding to a field in my DataRow and the field value is null, I get a " Object cannot be cast from DBNull to other types." Is there a special property I should set on this control to allow it to handle null values bound to it? I''d think the expected behavior would be to either show 0.00 % or just an empty text box. Thanks!

Administrator [Syncfusion]
Replied On September 21, 2004 08:01 PM

Hi, Thanks for your feedback on this issue. I do see this problem here, and have consulted the development team for their inputs on this issue. I will keep you posted on this. We appreciate your patience and cooperation. Regards, Guru Patwal Syncfusion, Inc.

Paul Laudeman
Replied On September 22, 2004 06:18 AM

This problem also appears with the DateTime control (again, unless I''m configuring the control wrong). The best work around I have now is just to display a default value (via the Binding Format event). This isn''t always the best solution, because we''d like to force the user to either enter what would be a default value (for a value type), or just clear out the box if they explicitly want the field to have no value. Thanks, and keep me posted! -Paul >Hi, > >Thanks for your feedback on this issue. I do see this problem here, and have consulted the development team for their inputs on this issue. I will keep you posted on this. We appreciate your patience and cooperation. > >Regards, >Guru Patwal >Syncfusion, Inc.

Administrator [Syncfusion]
Replied On September 22, 2004 09:03 PM

Hi Paul, We have now added a BindablePercentValue property to the PercentTextBox that can support databinding to DBNull values as well. Presently this feature is still internal, and is expected to be incorporated in the next release of Essential Suite (post v2.1.0.9 releases). I will test the DateTimePickerAdv for this issue and will get back to you on this as soon as possible. We appreciate your continued interest in Syncfusion products. Regards, Guru Patwal Syncfusion, Inc.

Paul Laudeman
Replied On September 24, 2004 08:35 AM

Thanks for the update, Guru. We''re presently on build past the latest public release, and are upgrading frequently for some other new features. If you could email me privately and let me know when these are implemented, we might get the new functionality in our next private release. Thanks! -Paul >Hi Paul, > >We have now added a BindablePercentValue property to the PercentTextBox that can support databinding to DBNull values as well. Presently this feature is still internal, and is expected to be incorporated in the next release of Essential Suite (post v2.1.0.9 releases). I will test the DateTimePickerAdv for this issue and will get back to you on this as soon as possible. We appreciate your continued interest in Syncfusion products. > >Regards, >Guru Patwal >Syncfusion, Inc.

Administrator [Syncfusion]
Replied On September 27, 2004 04:17 PM

Hi Paul, Please create an incident in Direct-Trac and I will update you with more information in this regard. Also, the DateTimePickerAdv works fine when databound to a DataSource that contains null values. Make sure that you use its BindableValue property for the databinding. Please refer to the test sample attached that illustrates this,and let me know if you need further assistance. Thanks for choosing Syncfusion products. Regards, Guru Patwal Syncfusion, Inc.

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.

;