home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.os.msdos.programmer
- Path: sparky!uunet!usc!sdd.hp.com!caen!destroyer!cs.ubc.ca!uw-beaver!news.u.washington.edu!carson.u.washington.edu!bytor
- From: bytor@carson.u.washington.edu (Jill Patterson)
- Subject: Re: OWL: Enabling Pushbuttons
- Message-ID: <1992Dec14.025725.9124@u.washington.edu>
- Sender: news@u.washington.edu (USENET News System)
- Organization: University of Washington
- References: <1992Dec13.190610.5534@sei.cmu.edu>
- Date: Mon, 14 Dec 1992 02:57:25 GMT
- Lines: 25
-
- weinstoc@sei.cmu.edu (Chuck Weinstock) writes:
-
- >I'm using Borland C++ 3.1 and OWL. My application has some push buttons on
- >the main window. I want to be able to selectively disable and enable those
- >buttons (and gray them when disabled). I figured out that I can disable a
- >button by setting WS_DISABLED in Attr.Style at creation. But I can't figure
- >out how to re-enable or re-disable the button thereafter. Can anyone help?
-
- >Chuck Weinstock weinstock@sei.cmu.edu
- >Software Engineering Institute (412) 268-7719
- >Carnegie Mellon University (412) 268-5758 (Fax)
-
- Chuck,
- Check out The EnableWindow(HWND, BOOL) Function. All
- you need to do is call that with the handle to the button window
- and TRUE for enabled, FALSE for disabled. Also look at the
- OWL function GetItemHandle(id) to get the handle to the button
- using its resource id.
-
- Good Luck!
-
- bytor@carson.u.washington.edu
-
-
- >Pittsburgh, PA 15213
-