home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 18 REXX / 18-REXX.zip / extspsht.zip / EXTSPSHT / Main / Form.1 < prev    next >
Text File  |  1997-07-17  |  1KB  |  52 lines

  1. /* Event Form events, Opened */
  2. Arg window 
  3.  
  4. CALL VpWindow window,'EXTENDEDHELP'
  5. CALL VpWindow window,'HELPINDEX'
  6.  
  7. SPRM.SET_EDTSTYLE = '0x101b'
  8. SPRM.GET_EDTSTYLE = '0x101c'
  9. SPRS.ENTER_EDITS  = 256
  10. SPRS.CHAR_EDITS   = 512
  11. SPRS.EDITFULLSEL  = 1024
  12. SPRS.EDITFIXLEN   = 2048
  13. SPRS.ALLOWDELETE  = 4096
  14. SPRS.GO_LEFT      = 8192
  15. SPRS.GO_DOWN      = 16384
  16.  
  17. SPRS.VIRTUALKEY   = 65536
  18. SPRS.KEY_SHIFT    = 16777216
  19. SPRS.KEY_CTRL     = 33554432
  20. SPRS.KEY_ALT      = 67108864
  21.  
  22. /* for the shift Flag */
  23. SPRM.OPTIMZE      = '0x101a'
  24. SPRS.OPTIMZE_ALLCOLS    =-1
  25. SPRS.OPTIMZE_COLS       =1
  26. SPRS.OPTIMZE_HEADER     =2
  27. SPRS.OPTIMZE_ROW_HEIGHT =4
  28.  
  29. SPRM.SET_READONLY  = '0x101e'
  30. SPRM.SET_EF_COLORS = '0x101f'
  31. SPRM.EDIT_CELL     = '0x1020'
  32.  
  33. /* Register the exstension and subclass the spreadsheet */
  34. call RxFuncAdd 'SbcSpsht', 'SBCSPSHT', 'SbcSpsht'
  35. SbcSpshtRV = SbcSpsht(VpItem(window, 'SPREADSHEET', 'GETHANDLE'));
  36.  
  37. /* Set item value 1002 Text */
  38. CALL VpSetItemValue window,1002,SbcSpshtRV
  39. /* Set cells 1000 Spreadsheet */
  40. DO col = 1 to 3 by 1
  41.   DO row = 1 to 10 by 1
  42.     CELLS.col.row = "Col"||col||"-Row"||row
  43.   END
  44. END
  45. CELLS.0 = 3
  46. CELLS.1 = 10
  47. /* Set maximum number of cells 1000 Spreadsheet */
  48. call VpSprSht window, 1000, 'SETNUMCELLS', CELLS.0, CELLS.1
  49.  
  50. CALL VpSprSht window, 1000, 'SETCELLS', 'CELLS.'
  51.  
  52.