home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / zeryxvp.zip / VPZXPBAR.HLP (.txt) < prev    next >
OS/2 Help File  |  2000-05-26  |  6KB  |  204 lines

  1.  
  2. ΓòÉΓòÉΓòÉ 1. Overview of Progress bar ΓòÉΓòÉΓòÉ
  3.  
  4. This object was developped with help from Ulrich M╨ñller the creator of XFolder 
  5. and XWorkPlace. 
  6.  
  7. The need for a decent progress bar API under OS2 as been unanswered for too 
  8. long, following Ulrich call to do what IBM and others did not do, i created 
  9. this object for Vipro Rexx and C. Now i am using for my software, and i am 
  10. giving this to all who want to improve OS2 by programming for it. 
  11.  
  12. This program is under GPL and no garanties are given use at your risk. for 
  13. information email to: elavoie@zeryx.com or go to http://www.zeryx.com. 
  14.  
  15.  
  16. ΓòÉΓòÉΓòÉ 2. Style page for the Progress bar ΓòÉΓòÉΓòÉ
  17.  
  18. There are several styles available for the Progress bar object. You can set the 
  19. styles using the style page or by using the methods associated with each style. 
  20.  
  21. Basic 
  22.  
  23. Tab stop 
  24. Allows the user to tab to the Progress bar.  It is a good idea to provide a tab 
  25. stop for the first Progress bar in a group. 
  26.  
  27. Group 
  28. Allows the user to move within a group of objects using the arrow keys.  Select 
  29. Group if this Progress bar is the only object in a group or if it is the first 
  30. object in a group. 
  31.  
  32. Disabled 
  33. The Progress bar is present, but the user cannot select it. 
  34.  
  35. Visible 
  36. The user can see the Progress bar. 
  37.  
  38. Other Styles 
  39.  
  40. PERCENT 
  41. Set progress bar as a percent display 
  42.  
  43. NUMERIC 
  44. Set progress bar as a numeric display 
  45.  
  46. BUTTONSTYLE 
  47. Give the progress bar a Button relief style 
  48.  
  49.  
  50. ΓòÉΓòÉΓòÉ 3. Methods for Progress bar ΓòÉΓòÉΓòÉ
  51.  
  52. The Progress bar supports the following methods: 
  53.  
  54. Update percent bar 
  55. Updates the progress with a min and max value 
  56.  
  57. Set PERCENT style 
  58. Turn on the PERCENT style option. 
  59.  
  60. Get PERCENT style flag 
  61. Query if the percent style is on. 
  62.  
  63. Set NUMERIC style 
  64. Turn on the NUMERIC style option. 
  65.  
  66. Get NUMERIC style flag 
  67. Query if the numeric style is on. 
  68.  
  69.  
  70. ΓòÉΓòÉΓòÉ 3.1. Update percent bar ΓòÉΓòÉΓòÉ
  71.  
  72. Description 
  73. Updates the progress it sets the current progress and the overall scale of the 
  74. progress bar. 
  75.  
  76. REXX Statement: 
  77. rc=VpZxPBar(window, %s, 'UPDVALUE',current_pos,max) 
  78.  
  79. Parameters: 
  80. This function is used to update the progress in the status bar. 
  81.  
  82. You have to give the current value of the progress and the maximum of the scale 
  83. (max). If a percent display is selected the value current_pos is divided by the 
  84. value max and multiplied by 100. If the display is set at numeric then the 
  85. current_pos value will be displayed, the max value will determine the scale of 
  86. the progress bar. 
  87.  
  88. Some validation are made to avoid errors, if max is at 0 then min is set to 0 
  89. and max to 1. 
  90.  
  91. window 
  92. The form in which the object resides. Also known as the window Handle 
  93.  
  94. itemid 
  95. The numeric ID or the symbolic name of the object. 
  96.  
  97. UPDVALUE 
  98. The method identifier.  This must be the literal string. 
  99.  
  100. current_pos 
  101. Current pos for the progress indicator. 
  102.  
  103. max 
  104. The maximum of the scale, it can be changed on each call 
  105.  
  106. Returns: 
  107. Allways returns 0. 
  108.  
  109.  
  110. ΓòÉΓòÉΓòÉ 3.2. Get PERCENT style flag ΓòÉΓòÉΓòÉ
  111.  
  112. Description 
  113. Query the status of the PERCENT style option. The PERCENT style Set progress 
  114. bar as a percent display 
  115.  
  116. REXX Statement: 
  117. flag=VpZxPBar(window, itemid, "GETPERCENT)" 
  118.  
  119. Parameters: 
  120.  
  121. window 
  122. The form in which the object resides. 
  123.  
  124. itemid 
  125. The numeric ID or the symbolic name of the object. 
  126.  
  127. GETPERCENT 
  128. The method identifier. 
  129.  
  130. Returns: 
  131.  
  132. flag 
  133. 1 if style is set, else 0. 
  134.  
  135.  
  136. ΓòÉΓòÉΓòÉ 3.3. Set PERCENT style ΓòÉΓòÉΓòÉ
  137.  
  138. Description 
  139. Turn on the PERCENT style option. The PERCENT style Set progress bar as a 
  140. percent display 
  141.  
  142. REXX Statement: 
  143. CALL VpZxPBar window, itemid, "SETPERCENT" 
  144.  
  145. Parameters: 
  146. Purpose 
  147.  
  148. window 
  149. The form in which the object resides. 
  150.  
  151. itemid 
  152. The numeric ID or the symbolic name of the object. 
  153.  
  154. SETPERCENT 
  155. The method identifier. 
  156.  
  157.  
  158. ΓòÉΓòÉΓòÉ 3.4. Get NUMERIC style flag ΓòÉΓòÉΓòÉ
  159.  
  160. Description 
  161. Query the status of the NUMERIC style option. The NUMERIC style Set progress 
  162. bar as a numeric display 
  163.  
  164. REXX Statement: 
  165. flag=VpZxPBar(window, itemid, "GETNUMERIC)" 
  166.  
  167. Parameters: 
  168. Purpose 
  169.  
  170. window 
  171. The form in which the object resides. 
  172.  
  173. itemid 
  174. The numeric ID or the symbolic name of the object. 
  175.  
  176. GETNUMERIC 
  177. The method identifier. 
  178.  
  179. Returns: 
  180.  
  181. flag 
  182. 1 if style is set, else 0. 
  183.  
  184.  
  185. ΓòÉΓòÉΓòÉ 3.5. Set NUMERIC style ΓòÉΓòÉΓòÉ
  186.  
  187. Description 
  188. Turn on the NUMERIC style option. The NUMERIC style Set progress bar as a 
  189. numeric display 
  190.  
  191. REXX Statement: 
  192. CALL VpZxPBar window, itemid, "SETNUMERIC" 
  193.  
  194. Parameters: 
  195. Purpose 
  196.  
  197. window 
  198. The form in which the object resides. 
  199.  
  200. itemid 
  201. The numeric ID or the symbolic name of the object. 
  202.  
  203. SETNUMERIC 
  204. The method identifier.