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 TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Passing form data to report

Status
Not open for further replies.

ZOR

Technical User
Jan 30, 2002
2,963
GB
If I have a table where one field contains data such as "Dog,Chicken,Bear" or "Fish,Cow,Pig" How can I fill a listbox from the table where only the first part of the data up to the comma gets added to my list?
Many thanks
 
Have a look at the Left, Right, Mid and InStr Functions.

Something lik

Left(field, Instr(0, field, ",") - 1)

should get you started

=======================================
People think it must be fun to be a super genius, but they don't realize how hard it is to put up with all the idiots in the world. (Calvin from Calvin And Hobbs)

Robert L. Johnson III
CCNA, CCDA, MCSA, CNA, Net+, A+, CHDP
VB/Access Programmer
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top