Product ID, Product Name 
Author Message
 Product ID, Product Name

Hi, I am new to VBA, and all help is much appreciated.

I am trying to write a program on a form that will when a ProductID is
entered will retrieve ProductName from another table, and put it onto the
form.  I have tried to use the DLookup procedure, but it does not seem to be
working.

All help is much appreciated.

Many thanks.



Sun, 25 Jan 2004 05:33:03 GMT  
 Product ID, Product Name
On Tue, 7 Aug 2001 22:33:03 +0100, "Dollar"

Quote:

>Hi, I am new to VBA, and all help is much appreciated.

>I am trying to write a program on a form that will when a ProductID is
>entered will retrieve ProductName from another table, and put it onto the
>form.  I have tried to use the DLookup procedure, but it does not seem to be
>working.

Hm. Ordinarily no VBA code whatsoever is needed. If you have the
ProductID as a field on your Form's recordsource, the simplest way to
display the product name while storing the ID (which ordinarily should
be unseen) is to use a Combo Box control based on the Products table.
Make the ProductID the bound field and the Control Source, and the
product name the first (or only) non-zero width field. The Toolbar
Combo Box wizard will help you set this up.

Or, you can base the Form on a Query joining the Product table to your
current recordsource, and pick up the product name from the joined
table.

                  John W. Vinson[MVP]    
    Come for live chats every Tuesday and Thursday
http://go.compuserve.com/msdevapps?loc=us&access=public



Sun, 25 Jan 2004 06:29:48 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Product A = Product B + Product C + .......

2. When does the Word PID (Product ID change)

3. How to read product ID?

4. Retrieve Office Product ID?

5. Lost Product ID for VB 6.0

6. Req: ?? Getting Product ID info

7. product number and user id

8. MS Office Product ID

9. Looking for Product ID

10. Req:?? Getting product ID info

11. VB 5.0 Product ID

12. VB5.0 Product ID

 

 
Powered by phpBB® Forum Software