View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
john john is offline
external usenet poster
 
Posts: 97
Default Excel VBA problem


Mark it sounds like you could accomplish this via
a vlookup to bring the age of the customer back to the
movies sheet, and the use an if(age<18,"warning","ok to
rent") or something like that.

The vlookup lets you find an entry in the left hand column
of a database and get an entry on that row.

John

-----Original 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/

.