مشکل در Binding a Date to a textbox
سلام،
من تمام اطلاعات Database رو میتونم Bind کنم، اما سر Date مشکل دارم و این Error رو میده: object reference not set to an instance of an object
اینم قسمتی از کد هست:
کد:
txt_NB1.DataBindings.Add("Text", Bind, "db_NB1", True)
txt_NB2.DataBindings.Add("Text", Bind, "db_NB2", True)
txt_NB3.DataBindings.Add("Text", Bind, "db_NB3", True)
txt_NB4.DataBindings.Add("Text", Bind, "db_NB4", True)
txt_NB5.DataBindings.Add("Text", Bind, "db_NB5", True)
txt_NB6.DataBindings.Add("Text", Bind, "db_NB6", True)
txt_Date.DataBindings.Add("Text", Bind, "db_Date", True)
اگر خط آخر رو حذف کنم هیچ مشکلی نیست، اما سر این Date ایراد میگیره. هرچی جستجو کردم به نتیجه ای نرسیدم.
ممنون میشم کسی کمک کنه