
Changing DataSet Position from another Form
To anyone that can help, I've now exhausted my help
resources and this is one of the last spots that I can
think of to get assistance on this issue.
I'm not sure if I'm just missing the obvious here, but
I'll lay out my problem:
What I have - A Visual Basic.NET (2003) project with a
MDI Container that contains a toolbar. The toolbar has
four buttons on it Start, Previous, Next, and End.
Next I have a MDI Child that loads into this container
and contains a dataset with a variety of contextbinded
fields.
What I'm trying to do basically is change the position
(i.e. via clicking the next button) of the dataset. Now I
can do this easily if I create a button on the same child
form, in it calling this function:
Public Sub func_nav_next()
Me.BindingContext
(objds_main_data, "table1").Position = (Me.BindingContext
(objds_main_data, "table1").Position + 1)
End Sub
However, when I try calling this same (public, shared)
function from the MDI Container, nothing happens.
Any ideas anyone?
Thank You for any help,
Jessee Holmes
Additional Information:
Just for information, I have made the forms available to
the entire project through this method so I can call
controls from one another.
Public Module globals
Private g_mdi_child As frm_mdi_child
Private g_mdi_parent As frm_mdi_parent
Public Property frm_mdi_child() As frm_mdi_child
Get
If g_mdi_child Is Nothing Then
g_mdi_child = New frm_mdi_child
End If
Return g_mdi_child
End Get
Set(ByVal Value As frm_mdi_child)
g_mdi_child = Value
End Set
End Property
Public Property frm_mdi_parent() As frm_mdi_parent
Get
If g_mdi_parent Is Nothing Then
g_mdi_parent = New frm_mdi_parent
End If
Return g_mdi_parent
End Get
Set(ByVal Value As frm_mdi_parent)
g_mdi_parent = Value
End Set
End Property
End Module