Solved

Access 2003 - Add a new record want subform to pop up and populate with inform from main form

Posted on 2007-11-30
4
603 Views
Last Modified: 2013-11-28
I have an Access 2003 form. It is patient history/information. When I add a new visit for that patient I would like to be able to have the form pop up to add this information and then also populate it with some information from the main form.
0
Comment
Question by:Pdeters
  • 2
4 Comments
 
LVL 17

Expert Comment

by:Shanmuga Sundaram
ID: 20382866
yes. you can do. try coding via vba.
0
 
LVL 120

Expert Comment

by:Rey Obrero (Capricorn1)
ID: 20383004
open your popup form with the patient id as open args

docmd.openform "frmVisit", openargs:= me.patientid

in the load event of the popup form

private sub form_load()

if  not isnull(me.openargs) then
    me.patientId=me.openargs
end if

end sub
0
 
LVL 120

Accepted Solution

by:
Rey Obrero (Capricorn1) earned 500 total points
ID: 20383062

better to open the form in add mode

docmd.openform "frmVisit",datamode:=acformadd, openargs:= me.patientid
0
 

Author Closing Comment

by:Pdeters
ID: 31411926
worked wonderful!!!
0

Featured Post

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying 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

A simple tool to export all objects of two Access files as text and compare it with Meld, a free diff tool.
In earlier versions of Windows (XP and before), you could drag a database to the taskbar, where it would appear as a taskbar icon to open that database.  This article shows how to recreate this functionality in Windows 7 through 10.
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 …

730 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