View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
Bob Phillips[_6_] Bob Phillips[_6_] is offline
external usenet poster
 
Posts: 11,272
Default Excel VBA problem

You need a VLOOKUP into the movies database to get the movies details and
another into Customer to get DoB, and use a simple IF to check if okay. You
could highlight discrepancies with Data Validation of conditional
formatting.

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

"Mark1ace1 " wrote in message
...
Being new to Excel and only just getting around formula's, I would have
no idea about how to write a simple VBA program. I was told the best
place to go would be this excellent forum (Hint!!!!)...My problem is
this..

I have a DVD database with three worksheets. First one is called
Movies, 2nd Customer Info and third customers.

Basically in Movies, I have name of movie and Ratings etc with cust
name. For instance Rating is in G9:G64), Customer name in J9:J64..Now
what I want to do is if a customer tries to rent a movie and it is R18
or R15 depending on Age..The vba would check sheet3/customers for their
age and date of birth and if that DOB is under 18 a message would
display that person is under age and not allowed to rent movie
parse...I have tried Data Validation but that only brings up message
when something is inputted into a cell, for instance I tried to create
a cell which linked to DOB and if it brought back under 18 it would
show message but Data validation never worked...Hope this message is
not too long...:(

Mark


---
Message posted from http://www.ExcelForum.com/