creating if statements with 3 options
Hey
I have a Choose from List with 2 items, that if selected will pass the variable through for the Code variable.
But if the variable for Code is not set from the previous selection, i want the option to type a variable for Code.
but it does not ask for input even if there is no previous selection for the Code variable.
Can someone please point out my stupidity 🙂 ?
if answer1 is equal to "PACKAGING" then
set Code to "TA01"
else
if answer2 is equal to "IPOP" then
set Code to "TA02"
else
set Code to text returned of (display dialog ¬
"Enter Code:" with title ¬
"Create Client Folder " with icon 1 ¬
default answer ¬
"" buttons {"Cancel", "Next…"} ¬
default button 2)
end if
end if
Applescript-OTHER, Mac OS X (10.7.4)