home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #18 / NN_1992_18.iso / spool / comp / sys / mac / hypercar / 3176 < prev    next >
Encoding:
Internet Message Format  |  1992-08-20  |  965 b 

  1. Path: sparky!uunet!dtix!darwin.sura.net!mips!sdd.hp.com!elroy.jpl.nasa.gov!orchard.la.locus.com!optimla!mike
  2. From: mike@optimla.aimla.com (Mike Diehr)
  3. Newsgroups: comp.sys.mac.hypercard
  4. Subject: Saving Insertion Point
  5. Message-ID: <1992Aug20.173641.4471@aimla.com>
  6. Date: 20 Aug 92 17:36:41 GMT
  7. Sender: news@aimla.com
  8. Organization: Philips Interactive Media
  9. Lines: 19
  10. Nntp-Posting-Host: chondrite
  11.  
  12. I received several responses to my question of how to update the contents
  13. of  field2 (via an Idle handler) while the user is typing in field1,
  14.  without the insertion point moving to field2 (which disrupts the user`s
  15. ability to type).
  16.  
  17.  
  18. The solution:
  19.  
  20. put the selectedchunk into X     -- remember the insertion point
  21.  
  22. -- do all field updating here
  23. put the length of field "user typing" into field "number of chars"
  24. put the number of words in field "user" into field "number of words"
  25.  
  26. -- now, restore the insertion point
  27. do "select" && X
  28.  
  29.  
  30. thanks to all that responded!
  31.