GetBar(), GetPad()
These functions let you figure out what's what in a popup or menu that's been rearranged in some way, either by having items released or by using a mover. GETBAR() is so confusing, we've ended up testing it every time we've ever needed to use it (but we think we've got it nailed now). Usage | nBarNumber = GETBAR( cPopupName, nBarPosition ) cPadName = GETPAD( cMenuName, nPadPosition ) |
Example | * Get the prompts of all bars picked from a mover multi-select * popup. LOCAL nCnt, nThisBar FOR nCnt = 1 TO CNTBAR() * first, get bar number of bar in current position nThisBar = GETBAR("MyPop", nCnt) * now, see if it's marked IF MRKBAR("MyPop", nThisBar) ? PRMBAR("MyPop", nThisBar) + " was chosen" ENDIF ENDFOR * Get the prompt of the third menu pad ? PRMPAD("_MSYSMENU", GETPAD("_MSYSMENU", 3)) |
See Also | Define Bar, Define Pad, Menus, PrmBar(), PrmPad() |
View Updates
Copyright © 2002 by Tamar E. Granor, Ted Roche, Doug Hennig, and Della Martin. All Rights Reserved.