home *** CD-ROM | disk | FTP | other *** search
/ Programming Tool Box / SIMS_2.iso / vb_code1 / at_spy / readme.txt < prev    next >
Text File  |  1994-06-16  |  2KB  |  49 lines

  1. ==============================================================
  2.     ATSPY (App.Title Spy)
  3.     Written by Atif Aziz, June 1994
  4. ==============================================================
  5.  
  6.  
  7. ABSTRACT
  8. --------
  9. This Visual Basic application, App.Title Spy (ATSPY.EXE)
  10. peeks into a Visual Basic generated EXE and retrieves the
  11. its application title string. This is the same string 
  12. contained by App.Title.
  13.  
  14. IMPORTANT
  15. ---------
  16. There is no documented method or API for retrieving the
  17. App.Title given a Visual Basic generated executable,
  18. therefore the method demonstrated in ATSPY.EXE is purely
  19. based on research. In numerous cases tested, ATSPY.EXE
  20. has never failed, so it can be considered sure and safe.
  21.  
  22. HOW DOES IT WORK?
  23. -----------------
  24. When an EXE is generated by Visual Basic, it invariably saves
  25. the App.Title string (provided in Make EXE File dialog box)
  26. in a user-defined resource (RCDATA) that has an id of 1.
  27. The string is always null-terminated and can be found at
  28. offset 0x13 (&H13 or 19 in base 10) from the beginning of
  29. the resource data. The length of the string, which includes
  30. the null-terminator, is also recorded at offset 0x0f (&HF 
  31. or 15 in base 10) into the resource data.
  32.  
  33. Armed with these two key facts, ATSPY.EXE opens a given
  34. EXE file in binary mode and reads several information
  35. tables to locate the resource. Once located, ATSPY reads
  36. in the data and uses the length from offset 0x0f and
  37. extracts those many characters from offset 0x19.
  38.  
  39. However, beware that this may change in future versions
  40. of Visual Basic. Moreover, ATSPY.EXE has only been tested
  41. with EXEs generated by Visual Basic 3.0 Professional Edition
  42. only.
  43.  
  44. HOW TO CONTACT THE AUTHOR?
  45. --------------------------
  46. Atif Aziz
  47. Internet: atif@infotec.ch
  48. CompuServe: 72644,3306
  49.