473,397 Members | 1,960 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,397 software developers and data experts.

Adding data through Pop-Up forms

12
Hi,
probably a very simple one this.
I have a data-input form that requires quite a few controls but has limited real estate. To get around this I've attached a pop-up form accessed through an "Advanced" button that displays the controls that are not normally used.
data entered

The problem I have is:
I enter data into the pop-up in the vain hope that it updates the record opened by the parent form, but this doesn't seem to happen.
I believe this is due to the OpenForm method (called when the button is pressed) that I'm using but I dont know enough about SQL to write a correct 'where' statement

Any help greatly appreciated


Code: ( text )
Private Sub Command0_Click()
On Error GoTo Err_Command0_Click

Dim stDocName As String
Dim stLinkCriteria As String

strDocName = "subfrmInputVoiceMitelAdvanced"
strLinkCriteria = "[BOSSID]= Forms![Form_subfrmInputVoiceMitel]![BOSSID]"

DoCmd.OpenForm strDocName, , , strLinkCriteria

Exit_Command0_Click:
Exit Sub

Err_Command0_Click:
MsgBox Err.Description
Resume Exit_Command0_Click

End Sub
Sep 26 '07 #1
4 2093
hyperpau
184 Expert 100+
Change This:
Expand|Select|Wrap|Line Numbers
  1. strLinkCriteria = "[BOSSID]= Forms![Form_subfrmInputVoiceMitel]![BOSSID]"
To this:

Expand|Select|Wrap|Line Numbers
  1. strLinkCriteria = "[BOSSID]=" & Me!BOSSID

Hi,
probably a very simple one this.
I have a data-input form that requires quite a few controls but has limited real estate. To get around this I've attached a pop-up form accessed through an "Advanced" button that displays the controls that are not normally used.
data entered

The problem I have is:
I enter data into the pop-up in the vain hope that it updates the record opened by the parent form, but this doesn't seem to happen.
I believe this is due to the OpenForm method (called when the button is pressed) that I'm using but I dont know enough about SQL to write a correct 'where' statement

Any help greatly appreciated


Code: ( text )
Private Sub Command0_Click()
On Error GoTo Err_Command0_Click

Dim stDocName As String
Dim stLinkCriteria As String

strDocName = "subfrmInputVoiceMitelAdvanced"
strLinkCriteria = "[BOSSID]= Forms![Form_subfrmInputVoiceMitel]![BOSSID]"

DoCmd.OpenForm strDocName, , , strLinkCriteria

Exit_Command0_Click:
Exit Sub

Err_Command0_Click:
MsgBox Err.Description
Resume Exit_Command0_Click

End Sub
Sep 27 '07 #2
cyberdwarf
218 Expert 100+
FWIW
Maybe you could place the 'Advanced' controls on a hidden Tab/Page on the main form. That way, clicking the Advanced button would just make the hidden Page visible and switch focus .
HTH

Steve
Sep 27 '07 #3
Ericks
74
Hi,
probably a very simple one this.
I have a data-input form that requires quite a few controls but has limited real estate. To get around this I've attached a pop-up form accessed through an "Advanced" button that displays the controls that are not normally used.
data entered

The problem I have is:
I enter data into the pop-up in the vain hope that it updates the record opened by the parent form, but this doesn't seem to happen.
I believe this is due to the OpenForm method (called when the button is pressed) that I'm using but I dont know enough about SQL to write a correct 'where' statement

Any help greatly appreciated


Code: ( text )
Private Sub Command0_Click()
On Error GoTo Err_Command0_Click

Dim stDocName As String
Dim stLinkCriteria As String

strDocName = "subfrmInputVoiceMitelAdvanced"
strLinkCriteria = "[BOSSID]= Forms![Form_subfrmInputVoiceMitel]![BOSSID]"

DoCmd.OpenForm strDocName, , , strLinkCriteria

Exit_Command0_Click:
Exit Sub

Err_Command0_Click:
MsgBox Err.Description
Resume Exit_Command0_Click

End Sub
Not sure if still relevant or if I understood it correctly. I too use popup forms to fill in data input forms. To make sure it updates the Form I put a Refresh form statement in the popup's on close event.
Oct 6 '07 #4
missinglinq
3,532 Expert 2GB
The classic answer to too many controls for the real estate available is to do as Cyberdwarf has suggested; use a form with tabbed pages. You could hide the second page and have it appear with a click of the "advanced" button, or simply label the second page, with the seldom used controls, as "Advanced."

This way, referencing is easy, because the controls are, in actuality, on a single form. There's no problem trying to "sync" up the two forms, because there is no second form, and you avoid the problem of having two forms trying to write to a single table/query, for the same reason.

Linq ;)>
Oct 6 '07 #5

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

Similar topics

4
by: Roy Smith | last post by:
In the recent "transforming a list into a string" thread, we've been discussing the fact that list.pop() is O(1), but list.pop(0) is O(n). I decided to do a little timing experiment. To be sure,...
11
by: Qiangning Hong | last post by:
A class Collector, it spawns several threads to read from serial port. Collector.get_data() will get all the data they have read since last call. Who can tell me whether my implementation correct?...
9
by: Anon Email | last post by:
Hi people, I'm learning about header files in C++. The following is code from Bartosz Milewski: // Code const int maxStack = 16; class IStack
5
by: py | last post by:
I have some data (in a string) such as.... person number 1 Name: bob Age: 50 person number 2
18
by: xarax | last post by:
Greetings, What is the general practice, usual and customary way, of including a data file into a source file? I have some large data structures defined as source similar to: ...
5
by: Jon Kneller | last post by:
I have 2 seperate libraries, compiled to .so files (these are being loaded into a Tcl process). I would like to be able to share data (a linked list) between these libraries - one needs to...
1
by: Piotr Karwatka | last post by:
Hi! I need to do relation beetwen one table (task 2 task) and i do something like that" DataSet data = new DataSet(); myCommand.Fill(data);
3
by: Newcomsas | last post by:
Hello, I'm trying to solve a problem with JS textbox array without success. I have two buttons in my page: PLUS and MINUS; at every click on PLUS a new textbox named 'dear' is generated. So, if...
3
by: jacob navia | last post by:
Abstract: Continuing the discussion about abstract data types, in this discussion group, a string collection data type is presented, patterned after the collection in C# and similar languages...
1
by: Paul McGuire | last post by:
1. With the current dict, the following code a = { "A" : 1, "B" : 2 } b = { "B" : 2, "A" : 1 } a==b evaluates to True. I assume that if these were odicts, this would evaluate to False. ...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
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...
0
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,...
0
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...
0
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...

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.