PC Review


Reply
Thread Tools Rate Thread

DateTimePicker Binding problems

 
 
Chris W
Guest
Posts: n/a
 
      3rd May 2005
Hi,

I am trying to bind the DateTimePicker (have tried opennetcf and the
microsoft one) to a field in my database. The default value for this
field is "Now()", the problem comes when i change this using the
datetimepicker the field isnt changed in my database. Does anyone have
any ideas??

I am binding just using the normal binding code e.g.
mydatetimepicker.databindings.add(new
binding("Value",mydataset,"datefield"))

Thanks

Chris

*** Sent via Developersdex http://www.developersdex.com ***
 
Reply With Quote
 
 
 
 
Ilya Tumanov [MS]
Guest
Posts: n/a
 
      3rd May 2005
That's because it not supposed to. Data source is only updated on validation
event.

Move focus away from DTP and data in the dataset will be updated.



Also, if by data base you mean something other than dataset itself (say, SQL
CE), it won't be updated until you execute code to update it (e.g.
DataAdapter.Update()).



Best regards,



Ilya



This posting is provided "AS IS" with no warranties, and confers no rights.



"Chris W" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Hi,
>
> I am trying to bind the DateTimePicker (have tried opennetcf and the
> microsoft one) to a field in my database. The default value for this
> field is "Now()", the problem comes when i change this using the
> datetimepicker the field isnt changed in my database. Does anyone have
> any ideas??
>
> I am binding just using the normal binding code e.g.
> mydatetimepicker.databindings.add(new
> binding("Value",mydataset,"datefield"))
>
> Thanks
>
> Chris
>
> *** Sent via Developersdex http://www.developersdex.com ***



 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Binding DateTimePicker question dbuchanan Microsoft Dot NET Framework Forms 6 5th Oct 2007 03:49 AM
Binding DateTimePicker =?Utf-8?B?Sm9obiBTdGl2ZW5zb24=?= Microsoft ADO .NET 4 31st Dec 2006 08:05 AM
Re: Binding DateTimePicker ClayB Microsoft Dot NET Framework Forms 0 27th Dec 2006 02:11 PM
Issue binding a DateTimePicker to a DataView Lorenz Kahl Microsoft ADO .NET 5 3rd Sep 2004 05:42 PM
DateTimePicker and DataSet binding Rafal Ziolkowski Microsoft Dot NET Framework 1 26th Nov 2003 12:42 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 02:58 AM.