A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Using Forms
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Back again...



 
 
Thread Tools Display Modes
  #1  
Old December 23rd, 2004, 01:11 PM
Aaron Howe
external usenet poster
 
Posts: n/a
Default Back again...

I seem to be getting a really stupid error message up and
I don't know why. I have two forms, one main and one
sub. In the main form a record is selected using a combo
box, and then information to be added to that record can
be entered in the subform below. Because the information
is in two different tables, subforms were used with one
field from the combo box selection being copied into the
subform in order to maintain a link through the PK.

However, when I go to make a selection from the combo box
in the subform, I get an error message that a value is
required in the field and that I must fill it in - which
is what I am about to do, because the error comes up the
moment I click on the combo box control!

Any ideas why this would happen?
  #2  
Old December 23rd, 2004, 01:43 PM
Jeff Boyce
external usenet poster
 
Posts: n/a
Default

Aaron

If you have a mainform/subform design, you shouldn't have to copy a value
into the subform. Check the Parent & Child properties of the subform
control. Access will keep the two connected, and will automatically
generate a "foreign key" value in the subform.

This assumes that your underlying table structure includes a foreign key
field in your child table, pointing back to the primary key field in your
parent table.

Or have I misunderstood? If you forget the forms for a second, do you even
have parent and child tables, related one-to-many? Use of a
mainform/subform design is usually predicated on having a one-to-many data
relationship.

--
Good luck

Jeff Boyce
Access MVP

"Aaron Howe" wrote in message
...
I seem to be getting a really stupid error message up and
I don't know why. I have two forms, one main and one
sub. In the main form a record is selected using a combo
box, and then information to be added to that record can
be entered in the subform below. Because the information
is in two different tables, subforms were used with one
field from the combo box selection being copied into the
subform in order to maintain a link through the PK.

However, when I go to make a selection from the combo box
in the subform, I get an error message that a value is
required in the field and that I must fill it in - which
is what I am about to do, because the error comes up the
moment I click on the combo box control!

Any ideas why this would happen?


 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Back to where i was AMH Formatting Long Documents 4 August 10th, 2004 10:13 PM
Trouble with Send to Back Helene Publisher 1 August 10th, 2004 03:31 PM
Losing connection to the back end of database Gale Coleman General Discussion 4 August 10th, 2004 09:53 AM
go back in pivot tables Abel General Discussion 1 July 28th, 2004 03:40 PM
Outlook reverts back to 2000 Nate Weldon Installation & Setup 1 May 6th, 2004 06:51 PM


All times are GMT +1. The time now is 09:09 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.