want to clear databound textbox after populating


Author
Message
Greg
Greg
StrataFrame Beginner (23 reputation)StrataFrame Beginner (23 reputation)StrataFrame Beginner (23 reputation)StrataFrame Beginner (23 reputation)StrataFrame Beginner (23 reputation)StrataFrame Beginner (23 reputation)StrataFrame Beginner (23 reputation)StrataFrame Beginner (23 reputation)StrataFrame Beginner (23 reputation)
Group: Forum Members
Posts: 7, Visits: 52
I currently have a date textbox that has the bindingfield and businessobjectname properties set, and is populating based on that. However, since I am working with dates, I have set a NULL replacement value in the business object mapper of CDate("1/1/1800").

I would like the textbox to display nothing if the database field has a null value in it, however I have so far been unable to figure out how to clear the textbox if the date is 1/1/1800.

Is there a way to clear the textbox without using javascript? Is there a different value I could be using in the business object mapper for the NULL replacement value?
Replies
Teddy Jensen
Teddy Jensen
StrataFrame User (152 reputation)StrataFrame User (152 reputation)StrataFrame User (152 reputation)StrataFrame User (152 reputation)StrataFrame User (152 reputation)StrataFrame User (152 reputation)StrataFrame User (152 reputation)StrataFrame User (152 reputation)StrataFrame User (152 reputation)
Group: StrataFrame Users
Posts: 52, Visits: 8K
Hi Greg,

I use "new DateTime(1800,1,1)" as alternate value in the bo, and it works for me when using SF datetimepicker.

This just so you maybe could narrow your problem down to the subclassed textbox, if it doesn't work.



/Teddy
Edited 15 Years Ago by Teddy Jensen
Greg McGuffey
Greg McGuffey
Strategic Support Team Member (4.8K reputation)
Group: Forum Members
Posts: 2K, Visits: 6.6K
Teddy right on the money. The web adds some complexity so sometimes it's a good idea to create a mini test project, a SF C# (or VB.NET...whatever you use) Winform app, copy your BO over, and see if it works. If the BO is working, then you have an issue with the TextBox, but likely it is a configuration issue.  I've attached an image showing the settings in the BO mapper.
Attachments
SF.BOMapper.NullSettings.png (216 views, 34.00 KB)
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...





Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search