home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 10 / 10.iso / l / l406 / 1.ddi / EDIT.FR_ / EDIT.bin (.txt)
Encoding:
Visual Basic Form  |  1992-10-21  |  7.5 KB  |  194 lines

  1.     frmEditor
  2. Text Editor: Untitled
  3. MS Sans Serif
  4. Form2
  5. txtEdit
  6. MS Sans Serif
  7. mnuFile
  8. &File
  9. mnuFileItem
  10. mnuFileItem
  11. &Open...
  12. mnuFileItem
  13. Save &As...
  14. mnuFileItem
  15. &Close
  16. mnuFileItem
  17. mnuFileItem
  18. E&xit
  19. mnuFileArray
  20. mnuEdit
  21. &Edit
  22. mnuEditItem
  23. mnuEditItem
  24. C&opy
  25. mnuEditItem
  26. &Paste
  27. mnuSettings
  28.     &Settings
  29. mnuSettingsItem
  30. &Colors
  31. mnuColorsItem
  32. &BackColor
  33. mnuBackColorItem
  34. mnuBackColorItem
  35. &Green
  36. mnuBackColorItem
  37. &Blue
  38. mnuColorsItem
  39. &ForeColor
  40. mnuForeColorItem
  41. mnuForeColorItem
  42. &Green
  43. mnuForeColorItem
  44. &Blue
  45. mnuBlueItem
  46. &Light Blue
  47. mnuBlueItem
  48. &Dark Blue
  49. mnuDarkBlueItem
  50.     &Sea Blue
  51. mnuDarkBlueItem
  52. &Midnight Blue
  53. mnuSettingsItem
  54. &Font Sizes
  55. mnuFontSizesItem
  56. mnuFontSizesItem
  57. mnuAbout
  58.     &About...
  59.     Form_Load
  60. Screen
  61. Height
  62. Left[
  63. Width
  64. Form_QueryUnload
  65. Cancel
  66. UnloadMode{
  67. DoUnLoadPreCheck
  68. Form_Resize
  69. txtEdit
  70. Scalewidth
  71. Scaleheight
  72. mnuAbout_Click
  73. CaptionText1
  74. CaptionText2
  75. CaptionText3
  76. CaptionText4
  77. CaptionText5
  78. frmAboutL
  79. lblAbout 
  80. Caption
  81. mnuBackColorItem_Click
  82. Index
  83.     BackColor
  84. mnuBlueItem_Click
  85.     ForeColor    
  86. mnuDarkBlueItem_Click6
  87. mnuEditItem_Click
  88.     Clipboardw
  89. SelTexth
  90. mnuFileArray_ClickX
  91. OpenFile
  92. mnuFileArray
  93. mnuFileItem_Click
  94. filename
  95.     frmEditor
  96. frmOpenSavee
  97. txtOpenSave
  98.     SelLength,
  99. mnuFileItem@
  100. Enabled
  101.     Closefile
  102. mnuFontsItem_ClickK
  103. mnuFontSizesItem_Click
  104. FontSize
  105. mnuFontSizesItem
  106. Checked
  107. mnuForeColorItem_Click
  108. txtEdit_Change
  109. txtEdit_KeyDown
  110. KeyCode
  111. Shift
  112. mnuEditItem
  113. mnuEdit_Click
  114. Form_Load
  115.  Change working directory to the directory
  116.  where the application was executed.
  117.  The form is horizontally and vertically centered when loaded.
  118. Form_QueryUnload
  119.  The general procedure DoUnLoadPreCheck handles the possible unload options.
  120.  for all three forms in this sample application.
  121. Form_Resize
  122. mnuAbout_Click
  123.  All the CaptionTextn string variables below are concatenated together with the appropriateg
  124.  line feed characters to display text in the About dialog.
  125. This Text Editor sample application illustrates the various menu features available using Visual Basic, including...
  126. ...submenus, separator bars, access keys, shortcut keys, modal and modeless dialog boxes,
  127.  MsgBox, showing and hiding forms, disabling controls, invisible controls, check marks,
  128.  control arrays, and adding and removing menu controls at run time...
  129. ...and much, much, more!
  130.  The Show method with style = 1 is used here to display the dialog as modal. Unloading the
  131.  dialog is handled in the forms cmdOK_Click event procedure.
  132. mnuBackColorItem_Click
  133.  Set BackColor to Red 
  134.  Set BackColor to Green
  135.  Set BackColor to Blue
  136. mnuBlueItem_Click
  137.  If Light Blue was selected then set the Forecolor to light.
  138.  blue otherwise do nothing. 
  139. mnuDarkBlueItem_Click
  140.  Set ForeColor to Sea Blue
  141.  Set ForeColor to Midnight Bluet
  142. mnuEdit_Click
  143.  Disable Cut and Copy if no text selected.
  144. mnuEditItem_Click
  145.  If Index = 0, user chose "Cut"t
  146.  Copy selected text to Clipboard.i
  147.  Clear selected text from the document.
  148.  If Index = 1, user chose "Copy"
  149.  Copy selected text to Clipboard.t
  150.  If Index = 2, user chose "Paste"t
  151.  Paste Clipboard text (if any) into document.g
  152. mnuFileArray_Click
  153.  Open the selected file.
  154. mnuFileItem_Click
  155.  Check index value of selected menu item.i
  156.  If index = 0, the user chose "New"m
  157.  Clear text box 
  158. Untitled
  159.  Set the title bar caption to "Text Editor: Untitled".
  160. Text Editor: 
  161.  If index = 1, the user chose "Open..."p
  162.  Set caption of Open/Save dialog to "Open"
  163.  Set default text in File Name text box.
  164.  Show default text selected.
  165.  Show the File Open dialog.
  166.  If index = 2, the user chose "Save As..."
  167.  Set caption of Open/Save dialog to "Save"
  168.  Set default text in File Name text box.
  169.  Show default text selected.
  170.  Show the File Open dialog.e
  171.  If index = 3, the user chose "Close"g
  172.  Clear text box 
  173. Text Editor: Untitled
  174.  Refresh caption of form
  175.  Disable this menu item.
  176.  Close the current file.
  177.  This menu item is a separator bar, no code needs to be written here
  178.  because it cannot be selected and therefore cannot receive a Click event.
  179.  If index = 5, the user chose "Exit"
  180.  End this application and return to the Windows operating system. 
  181. mnuFontSizesItem_Click
  182.  Perform action based on Index property value of menu control
  183.  If Index = 0 then user chose font size 12
  184.  Set FontSize property of text box to 12
  185.  Display check mark next to 12
  186.  Remove check mark next to 242
  187.  Set FontSize property of text box to 24
  188.  Remove check mark next to 12b
  189.  Display check mark next to 24
  190. mnuForeColorItem_Click
  191.  Set ForeColor to Rede
  192.  Set ForeColor to Green
  193.  No code for this case because submenu is automatically displayed on Case 2.
  194.