Option MenuPick in iOS

RevList RevList at CreaTECHSol.com
Sat Dec 25 19:48:24 EST 2010


I am working on my first app for iOS and have an option menu button that
works fine in the IDE but not in the Simulator.
When the card loads, it populates the menu options of the option menu
button from values in a field on the card

   put empty into button SiteList
   put "Select Site" into line 1 of button SiteList
   Put "New Site" into line 2 of button SiteList
   repeat with i = 3 to the number of Lines in fld  SiteData + 2
      put Item 1 of  line i-2 of field SiteData into line i of button
SiteList
   end repeat
   set the label of btn SiteList to "Select Site"

That works fine.

When I select one of the menu items it should then populate other fields
on the card and this works fine in the IDE, but not in the simulator.

It appears as the menuPick is not recognized at all.

Any ideas?

on menuPick pItemName   
   Put the MenuHistory of button "SiteList" into theLine
   if theLine > 2 then
      Put pItemName into field "SiteName"
      Put item 2 of line theLine - 2 of field "SiteData" into field "Lat"
      Put item 3 of line theLine - 2 of field "SiteData" into field "Long"
   End If
end menuPick


******************************************
Stewart Lynch
CreaTECH Solutions
slynch at CreaTECHSol.com
604.484.8499
Skype:StewartLynch

There are only 10 kinds of people.  Those who understand binary and those
who don't.
******************************************




More information about the Use-livecode mailing list