Display dialog when menu bar item is pressed?

Hi, I’m new to AppleScriptObjC… I’ve got a menu bar item in the “Window” menu of my application. I’m not sure how to display a dialog when that menu bar item is clicked.

Model: MacBook Pro
AppleScript: 2.1.2
Browser: Google Chrome 5.0.342.9
Operating System: Mac OS X (10.6)

You just need to connect it to a method in your applescript just like you would for a button. So, you could create a method like:

on doSomething_(sender)
		display dialog "I clicked on my menu item."
	end doSomething_

Save your applescript, then go to IB and control drag from your menu item to the app delegate for your program and choose doSomething from the popup that appears.

Ric

Thanks very much rdelmar =)