PDA

View Full Version : Validating an entry against a database



lucpian
05-19-2008, 12:32 PM
Hi All,

I am having problem writing a vba code in excel in validating an entry(Can2), against a database, and if the can2 is found in the database it gives a message stating valid entry, else it also gives a message of an invalid entry.

Please, I need your help.

Thanks

lucpian

Bob Phillips
05-19-2008, 12:48 PM
Where is the database, how are you querying it?

Show us what you have to date.

lucpian
05-19-2008, 01:01 PM
Hi All,
The database is an Access database which is located on the M drive, and the Can2 entries are queried against the database. I am not too comfortable with Execl, but will be very grateful if you could address my issues.

Thanks

LUCPIAN:doh:

Bob Phillips
05-19-2008, 02:37 PM
Have you tried querying the database via Data>Import External data>New Database Query. Run a query with the macro recorder on and you will get most of the code. After that, e can help you finish it.