Variable not defined?

Hey guys.

I’m getting a “Variable not defined” error. Here’s the script:

property Vendor : ""

on clicked theObject
	tell window of theObject
		set Vendor to the name of current menu item of popup button "idPopup"
		if Vendor is "Antares" then
			my idFolders("a")
		end if
	end tell
end clicked

When I click the button, I get an error “The variable Vendor is not defined.”
How can I be getting that error?

Any thoughts?

Thanks
-Rob

Have you tried using this:

set Vendor to title of current menu item of popup button "idPopup"

Bruce,

You’re a genius!! I was getting ready to resort to an AppleScript “Choose from list” command. Many thanks.
-Rob