Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • User (Old forums)
    Member
    Post count: 23064
    #18186 |

    Hi all
    When I try to set the DatePicker’s TextBoxArea.Text in code I get an error “System.ArgumentException”
    Any Ideas?

    TIA

    Imported from legacy forums. Posted by beny (had 2098 views)

    User (Old forums)
    Member
    Post count: 23064

    You can’t set the text property, since what’s behind the text is not a string but a date. You need to use the Value property to do this.

    e.g.:

    winDatePicker1.Value = new DateTime( 2006, 9, 27 );

    Imported from legacy forums. Posted by André (had 3090 views)

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.