Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Wanet Telecoms Ltd on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Need to show valu and not Index PK value on form? 1

Status
Not open for further replies.
Oct 19, 2004
31
US
I have three tables

Projects
ProjectID (PK)
Project name

Parts
PartID(PK)
PartDescription

ProjectParts- Junction Table
ProjectPartID(PK)
ProjectID
PartID

I want to enter the parts used in the project from a form.
For this I use the ProjectParts table and, I made the form by using autoform: Datasheet view.

Now I get a drop down for PartsID as I have a one to many relationship between Parts and ProjectParts. But when I drop the combobox down I get the PartID(Index key value). I have tried to change the Bound Column number in the properties tab from "1" to the correct column number to get the combo box to dispaly the right data for me, it works but then I get an error.

"That I am choosing text data for a numeric field"

Now I am linking the table at the PK level so it is numeric so how an i get a value other than the PK value to display in the combobox?

Confused, very confused.


 
Sounds like you're having trouble with BOUND COLUMN, COLUMN COUNT, and COLUMN WIDTHS.

In your combo box's ROW SOURCE, what is in there? I'm assuming your table "Parts", which has two fields, PartID and PartDesc.

You'll want these settings:

COLUMN COUNT: 2
COLUMN WIDTHS: 0,1
0 hides the ID column, 1" for Desc
BOUND COLUMN: 1 the ID will go into the ProjectParts table

So check those settings and let us know how it goes.

Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
 
You are right. Thank u soo much, this little configuration has cleared up my confusion.

"COLUMN WIDTHS: 0,1 0 hides the ID column, 1" for Desc
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top