databinfing to text box

i have a database (bank account) with 3 rows inserted manually in the sql serevr.
when i open the form to add a new account i want the text box (which is disabled threw its properties) to show the current (new) account- 4 and not the first and the rest of the text box to insert the data to the new row..
i bind the text box like that:
textbox.databinging.add("Text",Accounttable."AccountID");
please help!!!!


Answer this question

databinfing to text box

  • RobertPalmer

    Take a look at this app.

    http://www.planet-source-code.com/vb/scripts/ShowCode.asp txtCodeId=2225&lngWId=10

    Basiclly you would just bind it like normal and on load or whatever you would call the currencymanagers .addnew() method

    me.bindingcontext(accounttable).addnew()

    Hope this helps.

  • databinfing to text box