DataGrid, great problem

  • Thread starter Thread starter Agnes
  • Start date Start date
A

Agnes

my datagrid, e.g store (1)Prodcut id (2) product name (3)unitprice)
I found a great problem under the following case:-

row(1) User keyin the data, Press Save, i can save the content.
I design some function to bring the default item e.g (F3)-product id will
become "TOYS", and unitprice is $50.00
now, for a new row(2), if use didn't keyin anyting, and just use my shortcut
key.
It cannot save in the dataset . Why ???
if i key in something in row(2), I will see a new row in row(3) . and I CAN
save the record.
If i didn't key anything , there is now new row in row(3) , and i can't save
anything.

Please help ~
 
I solve the problem by
Dim myRow = myTable.newrow()
myrow("productid") ="TOYs"
mytable.row.add(myRow)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top