473,789 Members | 2,671 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Main Form Linking to PopUp?

1 New Member
Hello,

Try to explain this as best as I can.
I have a main form with several cmd buttons, (Not interested in subforms for this project) that opens popup forms.

Example: Main form frmPerson, cmd button cmdVehicle, when clicked opens frmVehicle displaying control boxes to be populated by the user. My problem is that I can't figure out how to link this PopUp Form frmVehicle to the main form, frmPerson.

I tried openargs but when I attempt to create a new record, the form is refreshed and the openargs linking is not working.

Any help is greatly appreciated,

Thanks,
Dec 2 '06 #1
2 4116
ADezii
8,834 Recognized Expert Expert
Hello,

Try to explain this as best as I can.
I have a main form with several cmd buttons, (Not interested in subforms for this project) that opens popup forms.

Example: Main form frmPerson, cmd button cmdVehicle, when clicked opens frmVehicle displaying control boxes to be populated by the user. My problem is that I can't figure out how to link this PopUp Form frmVehicle to the main form, frmPerson.

I tried openargs but when I attempt to create a new record, the form is refreshed and the openargs linking is not working.

Any help is greatly appreciated,

Thanks,
'Assuming [ID] is the Linking Field between frmPerson and frmVehicle, and
'you are populating frmVehicle with Child Records to frmPerson:

In the Current() Event of frmVehicle place the following line of code:

Expand|Select|Wrap|Line Numbers
  1. Me![ID] = Forms!frmPerson![ID]
Dec 2 '06 #2
MMcCarthy
14,534 Recognized Expert Moderator MVP
Hello,

Try to explain this as best as I can.
I have a main form with several cmd buttons, (Not interested in subforms for this project) that opens popup forms.

Example: Main form frmPerson, cmd button cmdVehicle, when clicked opens frmVehicle displaying control boxes to be populated by the user. My problem is that I can't figure out how to link this PopUp Form frmVehicle to the main form, frmPerson.

I tried openargs but when I attempt to create a new record, the form is refreshed and the openargs linking is not working.

Any help is greatly appreciated,

Thanks,
You need to add criteria to the DoCmd.OpenForm statement

e.g.
Expand|Select|Wrap|Line Numbers
  1. Dim stLinkCriteria
  2.  
  3.    stLinkCriteria = "[ID]=" & Me.ID
  4.  
  5.    DoCmd.OpenForm "frmVehicle", , , stLinkCriteria
  6.  
Dec 3 '06 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

5
2861
by: Hemanth | last post by:
Hello there, I'm running a script that opens a popup window (which is basically a form with checkboxes and a submit button). When I click the submit button I want to run a PHP script and target the result to main page (I mean, update the parent page). My popup form looks like this: <form name="form1" action="run.php" method="get" target="???">
0
1433
by: Deano | last post by:
I have a main/subform arrangement which works well. The main form's parent records are about employees. The subform calculates their salary. I have now decided that the user can enter some splits in a popup form that I have built. So they click the Splits button and they can enter e.g 0.4 and 0.6 or any combination as long as it comes back to 1 (the reason for this is so they can allocate parts of the salary to different code areas)....
4
7018
by: Dave Boyd | last post by:
Hi, I have two very similar forms each with a subform. The main form gets a few fields from the user and passes this back to a query that the subform is bound to. The requery is done when the user enters the last qualifying field on the main form. In one case this works fine, the subform shows the data the user wants to update -- which means showing all the data put in previously (ie showing this via the requery and the continuous...
1
2155
by: NBruch | last post by:
Ok let me explain what im trying to do: i need a combo box which needs to be linked to a listbox (or combo box doesnt matter which really) then the listbox should bring up the record in a subform. so you pick a name (in the combo box in the main form) then it should bring up all the dates for which the person has a record for (in the list box or combo box) and then once you pick a date it should bring up the specific record you want...
1
2119
by: VMI | last post by:
How can I transfer some text from a Textbox in a popup window to the main webform that opened that popup? The popup webform will have some type of Button that the user will click in order to accept those changes. This is where the transter of the value should be. It could also be done when I close the popup form (whichever is easier). Once the popup form is closed, the value will then be used to fill a textbox in the main Form. I use...
6
5711
by: CJONES | last post by:
I have a main form and use a combo box to open a pop up form. The combo box lists customers and only one customer requires the fields that are found on the pop up form. I can get the form to pop up however I do not know how to link the pop up form data to the main form record.
2
1802
by: CJONES | last post by:
I have a main form with a combo box where if a specific customer is selected a popup form opens and additional information required for this customer is entered into the form. Data from the main form and popup form is stored in the same table. I have a field called certification that I would like to use to link the forms.
5
2458
by: Thelma Roslyn Lubkin | last post by:
I am still having trouble trying to use a popup form to allow user to set filters for the main form. The main form is based on a single table. The popup contains 5 listboxes, so the user can filter on 5 fields in this table, and can include as many field values as s/he needs. The popup is reached from a command button on the main form : This button is on the main form, Datasystem:
0
9511
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10412
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10200
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9986
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9021
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7529
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5422
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5551
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3703
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.