Path: utzoo!mnetor!uunet!lll-winken!lll-lcc!ames!pacbell!att-ih!ihnp4!inuxc!iuvax!pur-ee!uiucdcs!uxc.cso.uiuc.edu!uxg.cso.uiuc.edu!dorner From: dorner@uxg.cso.uiuc.edu Newsgroups: comp.sys.mac.programmer Subject: GetItemMark Message-ID: <40600005@uxg.cso.uiuc.edu> Date: 18 Mar 88 21:26:00 GMT Lines: 28 Nf-ID: #N:uxg.cso.uiuc.edu:40600005:000:918 Nf-From: uxg.cso.uiuc.edu!dorner Mar 18 15:26:00 1988 Does GetItemMark work? I'm trying to toggle a check mark on and off in a menu by seeing if the item is checked, and unchecking it if is, or checking it if it is not. Here's the code: /* Toggles the mark on a menu item. Returns the final state of the item. */ ToggleMark(theMenu,theItem) MenuHandle theMenu; int theItem; { char markChar; GetItemMark(theMenu,theItem,&markChar); SetItemMark(theMenu,theItem,(markChar==noMark) ? checkMark : noMark); return (markChar==noMark); } GetItemMark ALWAYS puts noMark in markChar, whether or not there is a checkmark by the item. The SetItemMark call then puts a checkmark by the item, and the routine returns 1. Am I doing something wrong? This is in LSC on an SE, for what that matters. ---- Steve Dorner, U of Illinois Computing Services Office Internet: dorner@uxc.cso.uiuc.edu UUCP: ihnp4!uiucuxc!dorner IfUMust: (217) 333-3339