Hi All,
I was trying to make a Generic Menubar Stack, but had the old problem
that the text changes depending on the name of the application, e.g.
"About thisApp", "About thatApp", ""About theOtherApp". Anyway, I
tried the following code and it worked! I hadn't realized before that
a parameter to a "case" clause can be a variable, which really makes
it a lot more powerful.
Just thought I'd share!
All the Best
Dave
---------------------------------------------------------------
--
-- menuPick
--
---------------------------------------------------------------
on menuPick theItemSelected
local myMenuItemNumber
local myAboutMenuItemText
local myAboutBoxStackLongName
--
-- Pull out the Text for the About Box Item
--
put line -1 of the text of me into myAboutMenuItemText
delete char 1 of myAboutMenuItemText
switch theItemSelected
case myAboutMenuItemText
--
-- Go to the About Window
--
put ISMGetStackForService(kAppServiceAboutBox) into
myAboutBoxStackLongName
if myAboutBoxStackLongName <> empty then
go to stack myAboutBoxStackLongName
end if
break
case "Help"
break
end switch
end menuPick
_______________________________________________
use-revolution mailing list
[email protected]
Please visit this url to subscribe, unsubscribe and manage your subscription
preferences:
http://lists.runrev.com/mailman/listinfo/use-revolution