Data Validation continued - Att Frank Kabel

  • Thread starter Thread starter Laurence Lombard
  • Start date Start date
L

Laurence Lombard

Frank
Please comment on my reply to my earlier posting. Older posts move so fast
down the list that I thought you might not notice it.

On my computer the posting is here

but you could also search for my name
Laurence Lombard
 
Hi Laurence

sorry I didn't see your reply. Bute to answer your questions:
1. Why do you use the Offset/Match statement instead of Vlookup - the latter
works as well and is simpler to understand.
Both work, but VLOOKUP required that you search the left column;
MATCH/OFFSET is more flexible. But in this case just a matter of taste
(and the copy/paste of existing code...).


2. Why is it necessary to Disable events for the Offset/Match function
to
work. I notice that I get an error message if I comment out the
"Application.EnableEvents = False" line but do not understand what it
means.
You shouldn't get an error but the reason behind this diabling is that
this procedure puts values into specific cells. To prevent the
triggering of other event procedures Application.events are disbabled.

HTH
Frank
 
Actually, the error is caused when you put the new value back in the cell. The
event fires again and the second time through, there isn't a match.
 
Hi Dave
you're right (I just looked at the code again). Thanks for the
clarification.
Frank
 
Back
Top