Solved

How populate form field with an option for a popup form

Posted on 2012-12-27
4
351 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
  • 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

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Question has a verified solution.

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

Suggested Solutions

Most if not all databases provide tools to filter data; even simple mail-merge programs might offer basic filtering capabilities. This is so important that, although Access has many built-in features to help the user in this task, developers often n…
Overview: This article:       (a) explains one principle method to cross-reference invoice items in Quickbooks®       (b) explores the reasons one might need to cross-reference invoice items       (c) provides a sample process for creating a M…
With Microsoft Access, learn how to start a database in different ways and produce different start-up actions allowing you to use a single database to perform multiple tasks. Specify a start-up form through options: Specify an Autoexec macro: Us…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

831 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