how do i save time in datagridview in vb.net 2010 [Newbie student] -
example press start time , time connected in textbox show when start time same out time,and when press save wont add datagridview. please me problem. save code:
private sub button6_click(byval sender system.object, byval e system.eventargs) handles button6.click table1bindingsource.addnew() me.validate() me.table1bindingsource.endedit() me.table1tableadapter.update(me.opendataset.table1) end sub
ok, solved problem....
here how form should :
and need add "time" columns datagridview:
and now... follow steps through image:
and here code :
public class form1 private sub button6_click(byval sender system.object, byval e system.eventargs) handles button6.click table1bindingsource.rows.add() table1bindingsource.rows(table1bindingsource.rows.count - 1).cells(0).value = textbox1.text & table1bindingsource.rows.count end sub private sub timer1_tick(byval sender system.object, byval e system.eventargs) handles counttimer.tick textbox1.text += 1 end sub end class
i hope answer useful :)
Comments
Post a Comment