Check the OpenArgs Property...

If your forms and control are keep on growing, I suggest put this on a table
so it will be more easy for you. Loop on the table and select...

HTH,
George


-----Original Message-----
From: Abraham [mailto:[EMAIL PROTECTED]
Sent: Wednesday, March 23, 2005 5:18 PM
To: [email protected]
Subject: [ms_access] Referring To A Control In A Closed Form




Hi,
I have code that opens different forms using Select case as follows:

Select Case intSelectedControl
    Case 1
        stDocName = "frmProductGroup1"

    Case 2
        stDocName = "frmProductGroup2"

.
.
.
End Select

    DoCmd.OpenForm stDocName, , , stLinkCriteria

I want to:
1) Specify a control on the appropriate form
Preferrably by storing its name in a variable, just like I have
stored the form name above.
2) Open the form
3) set the value of the control after opening the form.

How can I do that?

Thanks

Abraham






Yahoo! Groups Links










 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/ms_access/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to