display dialog in xcode

hi i am new to applescript studio. i am used to script editor. i want to make a dialog apear over the main interface how do i make this happen. i tried the display dialog command it dosent work

hi oj,

‘display dialog’ does work in AppleScript Studio. in addition, you can do things like:

display dialog "Here is a Dialog" attached to window "main"

and attach your dialog to the main window. perhaps you could supply the code that does not seem to be working?

or if you want a dialog to appear right when the app is launched you could do something like this

on launched theObject
	display dialog "This displays a dialog when your app is launched!"
end launched

How new? Do you know that you to connect event handlers in Interface Builder, and then put code inside of those handlers in your script file(s)?

right, i forgot that u said you were new, so for mine the first thing you have to do is in interface builder, get to the “File’s Owner” inspector (double click the icon where it says file’s owner) then in the drop down menu click “Applescript” at the bottom check off the checkbox that has your script name besides it. now above expand the menu that says application and check of “launched” then put my code in the previous post in your script.