home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.os.ms-windows.programmer.misc
- Path: sparky!uunet!psgrain!ee.und.ac.za!ucthpx!casper.cs.uct.ac.za!jholdern
- From: jholdern@casper.cs.uct.ac.za (J E Holderness)
- Subject: Cursor in list box & Multiple Instances
- Message-ID: <BuC584.CMu@casper.cs.uct.ac.za>
- Organization: Computer Science Department, University of Cape Town
- Date: Wed, 9 Sep 1992 23:57:40 GMT
- Lines: 29
-
- I have two problems which I'm hoping someone can help me with. The first
- is regarding the mouse cursor. I managed to change the cursor in a dialog
- box using the GetWindowClass function, and it worked fine, except that it
- changed back to the default arrow as soon as it was moved over a listbox
- or button.
-
- I don't mind the buttons so much, but the list box takes up most of the
- dialog area, so my pretty cursor hardly ever gets seen. Is there any way
- to fix this so that the cursor always stays as specified by the GetWindowClass
- function? Better still, is there an equivalent GetWindowClass function for
- each control or some way of controlling the cursor for each individual area
- of the dialog?
-
- My next problem is with multiple instances of an application. I can tell if
- a previous instance is running by checking the hPrevInstance variable,
- but having found that out, I can't seem to get any further. At the moment
- all I want to do is terminate the previous instance if it is running, but
- more general information on say passing messages to the application would
- be useful for future referance.
-
- I "discovered" a function called GetInstanceData, but I have no idea what
- it does. What exactly is the data that it returns? If I could obtain the
- MainWindow handle using this, then would I be able to send messages to
- that window (telling it to close for example)?
-
- Thanks in advance for any help.
-
- - Jim
-
-