you could also use SELECT CASE
but i've never try with the AND in a select case... but it should work.Code:select case MyVar case XYZ ' according stuff case XYZ AND ABC ' according stuff end select
Case not
Code:select case MyVar Case ABC If Myvar=XYZ then 'According stuff for Myvar = ABC AND =XYZ end select
Bookmarks