I'm making a game application in AppleScript. But when I was done it said this "Expected end of line but found ":".". The code I used was
display alert "By taping ok you accept the following rules: Do not hack, do not cheat, edit komponents or download our site to your desktop! If you do not follow these rules you could get banned"
if {button returned:"OK"}
tell application "/Applications/Safari.app"
open location http://www.pipadse.wix.com/games
end tell
Can anyone help?
A couple of things. First,
display alert
with nobuttons
parameter will just display anOK
button, so there's no real reason to check the result. However, if you still want to, or plan on adding additional buttons, you get the result by saving thedisplay alert
return value then testing thebutton returned
property of the value, something like this:And finally, if you're using this as some form of DRM, it's pretty weak.