View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Tushar Mehta Tushar Mehta is offline
external usenet poster
 
Posts: 1,071
Default If then several times

What do you mean by "why won't...if statements run?" Do you mean they
are not evaluated? Or that the 'do whatever' part is not executed?

What is the value of the active cell? What does the first 'DO
whatever' actually contain?

--
Regards,

Tushar Mehta
www.tushar-mehta.com
Excel, PowerPoint, and VBA add-ins, tutorials
Custom MS Office productivity solutions

In article ,
says...
I seem to be having a problem running a macro that uses several if then
statements. Here is an example... why won't the second third, fourth if
statements run?

If Activecell.value = 1 then
DO whatever
end if
If activecell.value =2 then
do whatever
end if
Ifactivecell.value = 3 then
do whatever
end if
end sub