Solved

How populate form field with an option for a popup form

Posted on 2012-12-27
4
370 Views
Last Modified: 2012-12-27
I have a form and the user can create a new record from the navigation bar at the bottom of the form.  There is no command button to add a new record.  When the user clicks the add record button (on the navigation bar at the bottom of the form) I want a form to popup that has three choices for the user to select from.  This form will have three option buttons... (M)anufacturing, (P)roposal, and (I)nstallation.  When the user has selected one of the three choices I need the first form to have a field populated with either a "M", "P", or "I" (from the form that popped up).  The name of the field on the first form is "txtDrawingType"   The name of the 1st form is "frmDrawings" and the name of the 2nd form is "frmTypeSelection".

There is a 2nd part to this question but since we are to ask only one question per topic, I will save it until this one has been resolved.

--Steve
0
Comment
Question by:SteveL13
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 61

Accepted Solution

by:
mbizup earned 500 total points
ID: 38724841
Is this an option group that you are working with?

If so, use the After Update event of the Option Group:

Select Case Me.fraYourOptionGroupName
        Case 1:
                 Forms!frmDrawings.txtDrawingType= "M"
        Case 2:
                 Forms!frmDrawings.txtDrawingType= "P"
        Case 3:
                 Forms!frmDrawings.txtDrawingType= "I"
End Select

Open in new window

0
 

Author Comment

by:SteveL13
ID: 38724870
Nice.  But how do I launch the 2nd form from the navigation bar on the bottom of the 1st form?
0
 

Author Comment

by:SteveL13
ID: 38724923
Actually, never mind.  I'm going to accept and go on to the 2nd question.
0
 
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 38724933
On the current event of the form:

Sub Form_Current()
    If me.NewRecord then
        DoCmd.OpenForm "frmYourSecondForm"
    End if
End sub


JeffCoachman
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Access developers frequently have requirements to interact with Excel (import from or output to) in their applications.  You might be able to accomplish this with the TransferSpreadsheet and OutputTo methods, but in this series of articles I will di…
In Part II of this series, I will discuss how to identify all open instances of Excel and enumerate the workbooks, spreadsheets, and named ranges within each of those instances.
Familiarize people with the process of retrieving data from SQL Server using an Access pass-thru query. Microsoft Access is a very powerful client/server development tool. One of the ways that you can retrieve data from a SQL Server is by using a pa…
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question