I have a form that when you click on the cmd button it will transfer the value of the text box to the other form.
This is the code I used....
Forms![PCV_Dispatch_form]![txtCodeSupervisor].Value = Me![txtCodeSupervisor].Value
When I look at the PCV_Dispatch_form I see that the value was transfered, but then what I would like to do is store the value in txtCodeSupervisor.
So I add the following in the PCV_Dispatch_form..
***************
Private Sub Form_Open(Cancel As Integer)
Public strCodeSupervisor As Integer
strCodeSupervisor = Me![txtCodeSupervisor].Value
end sub
But I keep on getting error that it can't contain a Null Value...Why is it that my value is not storing in my strCodeSupervior..
Can anyone please help..
Thanks in advance
This is the code I used....
Forms![PCV_Dispatch_form]![txtCodeSupervisor].Value = Me![txtCodeSupervisor].Value
When I look at the PCV_Dispatch_form I see that the value was transfered, but then what I would like to do is store the value in txtCodeSupervisor.
So I add the following in the PCV_Dispatch_form..
***************
Private Sub Form_Open(Cancel As Integer)
Public strCodeSupervisor As Integer
strCodeSupervisor = Me![txtCodeSupervisor].Value
end sub
But I keep on getting error that it can't contain a Null Value...Why is it that my value is not storing in my strCodeSupervior..
Can anyone please help..
Thanks in advance