The SET MARK OF command (not to be confused with SET MARK TO) lets you put a checkmark next to a menu bar or pad. The two functions ask whether an item is marked.
SET MARK OF MENU MenuName [ TO ] cMark | lMarkIt
SET MARK OF PAD PadName OF MenuName [ TO ] cMark | lMarkIt
SET MARK OF POPUP PopupName [ TO ] cMark | lMarkIt
SET MARK OF BAR nBar OF PopupName [ TO ] cMark | lMarkItSET MARK OF can be divided up two different ways. First, there are two kinds of values you can hand it: character and logical. In Visual FoxPro, the character values are ignored. (In FoxPro 2.x, they let you specify the mark character.)
The logical value determines whether the specified item has a checkmark character (like, for example, the item for the active window in Visual FoxPro's Window menu). When lMarkIt evaluates to .T., the item is checked.
However, like other menu commands, the MENU and POPUP versions of SET MARK propagate downward. If you SET MARK OF a popup to .T., all the bars on that popup get marked unless you issue a separate SET MARK OF BAR command to turn off particular bars. Similarly, SETting MARK OF a MENU TO .T. marks all the pads.
Incidentally, although Microsoft has chosen not to document it anymore, there is a SET MARK OF PAD command, and it does work for menu pads you define yourself.
SET MARK OF BAR 3 OF MyPopup TO .T.lIsMarked = MRKBAR( cPopupName, nBar | SystemBarName )
lIsMarked = MRKPAD( cMenuName, cPadName)MRKBAR() and MRKPAD() report whether the specified bar or pad has been marked. For system menu bars, you have to use the bar name, not in quotes. (Actually, that bar name is a number, a very negative number.)
* See GETBAR()Define Bar, Define Menu, Define Pad, Define Popup, GetBar(), GetPad(), Menus
