Solved

Synchronizing comboboxes in subform...

Posted on 2003-11-19
4
275 Views
Last Modified: 2010-08-05
OK, I haven't used Access since 1997 so I am a bit rusty, a good C programmer but just need to clear some cobwebs and it seems alot in Access that should be there isn't.
(I am converting a database from Lotus Approach with DBFs b/c IBM doesn't update the bugs and it is only partially relational and you have to do previews to see like SUMs and calculations)

I have searched and searched and found similar problems to mine but not exact:

I have a Purchase order program where the top part of the page which has the
PO number, Date, Entered by, Terms, etc. in the TABLE PURORDER and (the vendor info is in another TABLE that is linked).

This form is called: form_purorder2004

The SUBFORM (subform_puritems) contains the purchase order items from the TABLE: PURITEMS
Which contains fields, PO Number, PartNo(Combobox), UnitPrice(Combobox), Qty, calculated field: LINETOTAL (done in query),

Here is what I want to do i need to sychronize the two combo boxes....

When a PARTNO is selected I want the Unit price to show a list based on a query of the prior purchases and price. I made a query which has the PartNO, Unit Price, PODate, and Avg Price. I would like to show the 4 fields when the person clicks the down arrow on the Unit Price box.

1. Person selects PartNo from combobox list (they cannot add from here).
2. Next field with focus is the Unit Price, they click down arrow and should see the previous prices, date, po number and part number(for verification).
3. If the person needs to go back and enter price later (this happens ALOT), when they click into the Unit price combobox, it should be able to bring up the list.....

Now hold on .... HERE is the problem....

I actually got it to work - BUT if i ONLY look at the subform alone, but it doesn't work if I look at the form_purorder2004 with the subform embedded at the bottom in there.

I know that this is an issue, but I can't figure out how to implement anyone's solution...
I know you can't just change the RowSource b/c of the subform - i don't understand the reason -

Can a guru out there lend a hand???
0
Comment
Question by:moltar225
[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
 

Author Comment

by:moltar225
ID: 9777069
FYI - i am willing to send the database to anyone for debugging.  I can remove most of the data as right now it is 4mb zipped, or i can send it with the data i don't care, i've been up 2 days until 4 am trying to solve this one.  

Thanks.
0
 
LVL 9

Accepted Solution

by:
svenkarlsen earned 500 total points
ID: 9777156
Hi Moltar,

while you wait for a guru, I'd be glad to help you: sounds like there might be a glitch in some of your code - could you post the essential code from the comboboxes ?

That's just to save you some time, if this doesn't help:

1. do you refer to the form by screen.activeform ? (this would return the main form's name, even for the child form)


Regards,
Sven
0
 
LVL 32

Expert Comment

by:jadedata
ID: 9797956
0
 

Author Comment

by:moltar225
ID: 9859715
Yeah - i had to change the reference in the subform - I had it referenced when i created the subform as a form, and it needed to be like
[Forms]![frm_PURORDER2004]![2004subform_puritems].[Form]![cboPARTNO]

not
[Forms]![2004subform_puritems].[cboPARTNO]

because it was referenced in the subform on the new page. simple but frustrating, some things in Access are either totally illogical or too logical.

Thanks again.
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering 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

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.
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.
Using Microsoft Access, learn some simple rules for how to construct tables in a relational database. Split up all multi-value fields into single values: Split up fields that belong to other things into separate tables: Make sure that all record…
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 …

717 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