home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #20 / NN_1992_20.iso / spool / comp / os / mswindo / programm / tools / 921 < prev    next >
Encoding:
Internet Message Format  |  1992-09-09  |  1.7 KB

  1. From: galenr@hpgrla.gr.hp.com (Galen Raben)
  2. Date: Tue, 8 Sep 1992 17:28:59 GMT
  3. Subject: Re: VB: InputBox$ + 2 Option Boxes
  4. Message-ID: <36720012@hpgrla.gr.hp.com>
  5. Organization: Hewlett-Packard, Greeley, CO
  6. Path: sparky!uunet!cis.ohio-state.edu!zaphod.mps.ohio-state.edu!sdd.hp.com!scd.hp.com!hplextra!hpfcso!hpgrla!galenr
  7. Newsgroups: comp.os.ms-windows.programmer.tools
  8. References: <BtyM24.H04@wpi.WPI.EDU>
  9. Lines: 40
  10.  
  11. In comp.os.ms-windows.programmer.tools, mkim@wpi.WPI.EDU (Mansig Kim) writes:
  12.  
  13. >Could someone respond to this??
  14.  
  15. >I am implementing something like "InputBox$ + two option buttons" 
  16. >(call it MY-INPUT-BOX).
  17. ...
  18.  
  19. >Now, the problem is how to interrupt(WAIT) the calling until the user
  20. >selects one option button and clicks OK??
  21.  
  22. >for i = 1 to 10
  23. >    call MY-INPUT-BOX
  24. >    select one option box
  25. >    WAIT until OK clicked
  26. >    ^^^^
  27. >next
  28.  
  29. >Here is my way for the WAIT portion.
  30.  
  31. >DO Until OK-clicked
  32. >   idle(do dummy counting??)
  33. >Loop
  34.  
  35. Hmmm... looks like a good way to get locked into an infinite loop.
  36. If I understand the problem correctly(????) you can do away with your
  37. WAIT loop.  The OK command button should already have a click event set
  38. up... "Command1_Click" or whatever the cntlname of your OK button is.
  39. In the Command1_Click you could try to call your MY-INPUT-BOX.  Are you
  40. setting this up as a control array or do you have 10 forms set up for
  41. each of your input-boxes?  If you have 10 forms set up you can make each
  42. MODAL and then do a SHOW in the Command1_CLick to go to the next box (and
  43. lock the others out).
  44. In lieu of the above idea(s) you might try a DO_EVENTS (look in the VB
  45. manual) to break the dead-lock you get into in the WAIT portion of your
  46. code...
  47. Good Luck!
  48. - Galen -
  49. galenr@hpgrla.gr.com
  50.  
  51.