HI we have an automator workflow and I am trying to add some error handlers in applescript. This is so as to get the user to enter the correct information. It works but, if they entered it incorrectly again the variable would be set wrong. So i need to loop it until its correct.
Also how can i get it the script to distinguish between upper case and lowercase in the variable?
All works but I can’t get the repeat to work.
Please see below:
on run {input, parameters}
set input to (input as text)
if input contains " " = true then
set input to display dialog "Please re-enter the Division Code using no spaces & no lowercase letters" default answer input
set Input_DivCode to the text returned of the result
else
input contains " " = false
set Input_DivCode to the text of the input
end if
end run
Thanks for your help…