[AccessD] creating an inputbox form

Brett Barabash BBarabash at TappeConstruction.com
Wed Jul 23 12:03:38 CDT 2003


The trick is to not close the form, hide it instead.  Then, you can refer to
the control on the form from the calling form code.  I am assuming you are
opening the form in dialog mode, so the calling form code pauses until the
dialog is closed or hidden.  For example:
 
'Calling form code:
Private Sub cmdDialog_Click ()
 
    DoCmd.OpenForm "frmMyDialog", WindowMode:=acDialog
 
    If CurrentProject.AllForms("frmMyDialog").IsLoaded = True Then
        MsgBox Forms!frmMyDialog!txtSelection & " was selected."
        DoCmd.Close acForm, "frmMyDialog"
    End If
 
End Sub
 
'Dialog form code:
 
Private Sub cmdOK_Click ()
 
    Me.Visible = False
 
End Sub
 
Private Sub cmdCancel_Click()
 
    DoCmd.Close acForm, Me.Name
 
End Sub

-----Original Message-----
From: Don Elliker [mailto:delliker at hotmail.com]
Sent: Wednesday, July 23, 2003 11:40 AM
To: accessd at databaseadvisors.com
Subject: [AccessD] creating an inputbox form



Howdy,

I want to use my own form in place of the Inputbox. I am stuck on the part
where, after a user selection, I return the value selected. It's like this;
the user is on a form, makes a selection and up pops (my) inputbox. they
pick something and close it. How do I know what they picked?
TIA,

_d




"Things are only free to the extent that you don't pay for them".-Don
Elliker 

  _____  

MSN 8 helps ELIMINATE E-MAIL  <http://g.msn.com/8HMRENUS/2743??PS=> VIRUSES.
Get 2 months FREE*. 


--------------------------------------------------------------------------------------------------------------------
This email and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom
they are addressed.
If you have received this email in error please notify the
originator of the message. This footer also confirms that this
email message has been scanned for the presence of computer viruses.

Any views expressed in this message are those of the individual
sender, except where the sender specifies and with authority,
states them to be the views of Tappe Construction Co.

Scanning of this message and addition of this footer is performed
by SurfControl E-mail Filter software in conjunction with 
virus detection software.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://databaseadvisors.com/pipermail/accessd/attachments/20030723/be7f295f/attachment-0001.html>


More information about the AccessD mailing list