what is the best way of populating text boxes with values from the database. I am using access and want to display some values to two textboxes . I have been using the GetData method but I got a prpblem , in case the value is not found I want to call another form where it can be added to the database. the data being got is from the same table.
Jump to Post
If you want to show a form when there is no data then you would do something like:
If et.rows.count = 0 Then Dim addForm as New YourOtherForm addForm.Show 'Or use ShowDialog to keep it on top until closed Else TextBox2.Text = x.Price End If
All 7 Replies
Be a part of the DaniWeb community
We're a friendly, industry-focused community of 1.20 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.