W
Wan
Hi,
I have a test project consists of two forms. The main form contains a
datagrid and a button. On click of button I populate the datagrid with
a ds.table(0) so far so good and on grid's doublick event I bring up
the sub-form which contains controls such as text boxes, lookup, etc.
I can open the sub-form multiple times depending on the doubleclick of
the datagrid. I'm using databinding to bind controls in the sub-form.
on doubleclick event of datagrid ....
Dim frmsubform As New frmSub
frmsubform.Show()
frmsubform.txtAppNum.DataBindings.Add(New Binding("Text",
ds.Tables(0), "App"))
frmsubform.cbAppStatus.DataBindings.Add(New Binding("Text",
ds.Tables(0), "Status"))
The problem I'm having is that let's say I have 3 records in the
datagrid and I open the 1st record in the subform and then the 3rd
record in the subform. Now I have 2 sub forms showing records 1 & 3
but if click on 1st sub form and go back to 2nd sub form then both
forms have the identical recordset. How can I keep multiple subforms
with different records using databindings. Thanks in advance.
Wan
I have a test project consists of two forms. The main form contains a
datagrid and a button. On click of button I populate the datagrid with
a ds.table(0) so far so good and on grid's doublick event I bring up
the sub-form which contains controls such as text boxes, lookup, etc.
I can open the sub-form multiple times depending on the doubleclick of
the datagrid. I'm using databinding to bind controls in the sub-form.
on doubleclick event of datagrid ....
Dim frmsubform As New frmSub
frmsubform.Show()
frmsubform.txtAppNum.DataBindings.Add(New Binding("Text",
ds.Tables(0), "App"))
frmsubform.cbAppStatus.DataBindings.Add(New Binding("Text",
ds.Tables(0), "Status"))
The problem I'm having is that let's say I have 3 records in the
datagrid and I open the 1st record in the subform and then the 3rd
record in the subform. Now I have 2 sub forms showing records 1 & 3
but if click on 1st sub form and go back to 2nd sub form then both
forms have the identical recordset. How can I keep multiple subforms
with different records using databindings. Thanks in advance.
Wan