sanders720
Programmer
I have a flexgrid on form #2, and a textbox on both forms #1 and #2. The code below is on form #2.
When I click the flexgrid, the txtMatlCode.Value is populated based on the item in the row I selected. When I exit the form using the cmdExit function, I am hoping to populate the textbox on the other form with the same information.
Note, both forms are opened (shown) when I execute this part of the code.
Funny thing how it takes hours to do simple things like this, and only minutes to do the real impressive stuff! Anyhow, any help that can be provided is appreciated...
Thanks:
Private Sub msgDataGrid_Click()
Dim lcol As Integer
R = msgDataGrid.Row
For lcol = msgDataGrid.FixedCols To msgDataGrid.Cols - 1
msgDataGrid.Col = lcol
msgDataGrid.CellBackColor = &H80000002
Next lcol
Me.txtMatlCode.Value = msgDataGrid.TextMatrix(R, 1)
End Sub
Private Sub cmdExit_Click()
Dim MACODE As String
MACODE = frmMatlSearch.txtMatlCode.Value
frmPartProp.txtMatlCode.Value = MACODE
Me.hide
End Sub
When I click the flexgrid, the txtMatlCode.Value is populated based on the item in the row I selected. When I exit the form using the cmdExit function, I am hoping to populate the textbox on the other form with the same information.
Note, both forms are opened (shown) when I execute this part of the code.
Funny thing how it takes hours to do simple things like this, and only minutes to do the real impressive stuff! Anyhow, any help that can be provided is appreciated...
Thanks:
Private Sub msgDataGrid_Click()
Dim lcol As Integer
R = msgDataGrid.Row
For lcol = msgDataGrid.FixedCols To msgDataGrid.Cols - 1
msgDataGrid.Col = lcol
msgDataGrid.CellBackColor = &H80000002
Next lcol
Me.txtMatlCode.Value = msgDataGrid.TextMatrix(R, 1)
End Sub
Private Sub cmdExit_Click()
Dim MACODE As String
MACODE = frmMatlSearch.txtMatlCode.Value
frmPartProp.txtMatlCode.Value = MACODE
Me.hide
End Sub