Openarg returning value

Zigzag

Registered User.
Local time
Today, 18:44
Joined
Aug 19, 2007
Messages
386
Hi All,

I'm having a bit of a blonde moment on this and would like some help.

I am openeing a form (using VBA On click event of a text box) and passing on using OPENARG the Form name and text box name.

Code:
  DoCmd.OpenForm "Calendar", acNormal, "", "", , acNormal, "Forms![PlantListDetail]![ONDATE]"

When the form is opened I get the value of the text box of the previous form(Still open),Not a problem.

After changing this value I want to set the value of the previous forms text box to the new value I have set, but i am strugling with the correct syntax.

me.openargs passed to form equal "Forms![PlantListDetail]![ONDATE]"
returnvalue is the new value I have set using Calendar5 (calendar control)

Code:
Dim value As String
Dim Calledfrom As String
Calledfrom = Me.OpenArgs
returnvalue = Calendar5

Can anyone advise me how to do this?

'[Calledfrom]' = returnvalue

Garry
 

Users who are viewing this thread

Back
Top Bottom