Change label caption on another form

mafhobb

Registered User.
Local time
Today, 17:30
Joined
Feb 28, 2006
Messages
1,249
How do you change the caption of a label on another form. Both are open, the one I need to update (frmRepair) is behind the pop up form (frmAccept) that is changing it by clicking on a button.

I am trying this and it does not work
Code:
    Form(frmRepair).lblRMA.Caption = "RMA12345"

mafhobb
 
If you are going to provide the name of a form as an argument, it needs to be enclosed in speech marks.

Forms("frmRepair").lblRMA.Caption = "RMA12345"

Altrernatively
Forms!frmRepair.lblRMA.Caption = "RMA12345"
 

Users who are viewing this thread

Back
Top Bottom