Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Updating datasource of validating cell in cellvalidating
Message
From
29/12/2010 10:12:17
 
General information
Forum:
ASP.NET
Category:
Other
Environment versions
Environment:
VB 8.0
OS:
Vista
Network:
Windows XP
Database:
Jet/Access Engine
Miscellaneous
Thread ID:
01494012
Message ID:
01494101
Views:
51
>>You could always pad in your DataAcess class, before you actually save the field to the database table. Will that work for you?
>>
>>~~Bonnie
>

>Right... or handle the cellvalidated event in the base class, which is more generic. :).


Well, yes ... but you said you didn't want to do that, so I was looking for simple alternatives. <g>

Here's another sort of suggestion: if this had been a TextBox, I would have suggested using the Binding's Parse() event ... I don't use Grids all that much, so I'm not sure if there's a similar way of using the Parse() event with a grid cell, but it may be worth looking into ...

~~Bonnie



>>
>>
>>
>>>Is there a way to update the underlying bindingsource of the cell that is current in cellValidating? (i.e. without handling the cellvalidated event)?
>>>Assume you have a field that has 4 characters declared as string, but that contains a numeric value. If your user enters "5", you want to save " 5".
>>>It seems that you can update all the other cells in the way I need , but not the one that is current. It makes sense, but it's a pain no less. Any suggestions? I would find it kind of overkill to implement cellvalidated just for this.
>>>Thanks.
Bonnie Berent DeWitt
NET/C# MVP since 2003

http://geek-goddess-bonnie.blogspot.com
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform