home *** CD-ROM | disk | FTP | other *** search
/ Chip: 25 Years Anniversary / CHIP_25Jahre_Jubilaeum.iso / downloads / 401065 / WPO11 / Data1.cab / _CF8CC65B0A28479580452C1353705144 < prev    next >
Text File  |  2003-03-07  |  9KB  |  346 lines

  1. Else
  2.  
  3. Description
  4.  
  5. All statements between Else and Endif are executed when the If expression is False. See If.
  6.  
  7. ElseIfPlatform
  8.  
  9. Syntax
  10.  
  11. ([{<PlatformID>enumeration}])
  12.  
  13. Description
  14.  
  15. Works with IfPlatform and EndIfPlatform statements, similar to the Else statement in an If-Else-Endif control statement except that a new platform ID may be specified.
  16.  
  17. Parameters
  18.  
  19. <PlatformID> enumeration (optional, repeating)    List of platform IDs to test. If the ID of the current platform is specified, only the statements up to the next ElseIfPlatform statement are included in the macro (all others are ignored). If missing, the current "ignore" state is reversed (ignored statements are compiled up to the next ElseIfPlatform statement). Statements that would have been compiled are ignored; statements that would have been ignored are compiled.
  20.  
  21. _Version9_0_0! This enumeration is recognized if the macro is compiled using the version 0 PerfectScript macro system.
  22.  
  23. _Version9_0_1!
  24.  
  25. _Version9_0_3!
  26.  
  27. _Version9_0_4!
  28.  
  29. Win2000! Windows 2000 platform
  30.  
  31. CorelWine! Synonym for Linux in the Linux version of the Suite.
  32.  
  33. EndApp
  34.  
  35. Example
  36.  
  37. Syntax
  38.  
  39. (<ProductPrefix> identifier)
  40.  
  41. Description
  42.  
  43. Identify, for the compiler, an application that is no longer used in a macro (see Application).
  44.  
  45. Parameters
  46.  
  47. <ProductPrefix> identifier    A unique identifier that must match the ProductPrefix parameter of an Application statement, or the prefix of an OLE object variable. This command is a compile time only statement, and removes a product or object prefix from the product name list maintained by the macro compiler. If the prefix of the current default object or product is removed, the previous default prefix becomes the new default prefix.
  48.  
  49. Note
  50.  
  51.   EndApp is a non-executable statement that can occur anywhere in a macro. After EndApp, a product command to the application specified by EndApp creates a compile-time syntax error.
  52.   
  53. EndFor
  54.  
  55. Description
  56.  
  57. Close a For control loop. See For.
  58.  
  59. EndFunc
  60.  
  61. Description
  62.  
  63. Close a Function statement (synonym for EndFunction). See Function.
  64.  
  65. EndFunction
  66.  
  67. Description
  68.  
  69. Close a Function statement (synonym for EndFunc). See Function.
  70.  
  71. EndIf
  72.  
  73. Description
  74.  
  75. Close an If control statement. See If.
  76.  
  77. EndIfPlatform
  78.  
  79. Syntax
  80.  
  81. ([{<PlatformID>enumeration}])
  82.  
  83. Description
  84.  
  85. Close an IfPlatform conditional compile statement. See IfPlatform. The parameter is optional and ignored. Its only purpose is to document what it goes with.
  86.  
  87.  
  88.  
  89. EndProc
  90.  
  91. Description
  92.  
  93. Close a Procedure statement (synonym for EndProcedure). See Procedure.
  94.  
  95. EndProcedure
  96.  
  97. Description
  98.  
  99. Close a Procedure statement (synonym for EndProc). See Procedure.
  100.  
  101. EndPrompt
  102.  
  103. Description
  104.  
  105. Terminate the current Prompt. See Prompt.
  106.  
  107. EndSwitch
  108.  
  109. Description
  110.  
  111. Close a Switch control statement. See Switch.
  112.  
  113. EndWhile
  114.  
  115. Description
  116.  
  117. Close a While control loop. See While.
  118.  
  119. EndWith
  120.  
  121. Description
  122.  
  123. Close a With statement. See With.
  124.  
  125. string := EnvVariableGet
  126.  
  127. Syntax
  128.  
  129. ([EnvVariableName: string]; [EnvType: enumeration])
  130.  
  131. Description
  132.  
  133. Return the value of an environment variable.
  134.  
  135. Return Value
  136.  
  137. Environment variable value.
  138.  
  139. Parameters
  140.  
  141. EnvVariableName: string (optional)    The environment variable name. If not used, a list of all environment variables is returned.
  142.  
  143. EnvType: enumeration (optional)    The type of variable. If missing, DOS! is used.
  144.  
  145. DOS!
  146.  
  147. EnvVariableSet
  148.  
  149. Syntax
  150.  
  151. (EnvVariableName: string; [Value: string]; [EnvType: enumeration])
  152.  
  153. Description
  154.  
  155. Set the value of an environment variable, or delete it.
  156.  
  157. Parameters
  158.  
  159. EnvVariableName: string    The environment variable name.
  160.  
  161. Value: string (optional)    The value to assign to the variable. If missing, the environment variable is deleted.
  162.  
  163. EnvType: enumeration (optional)    The type of variable. Default: DOS!
  164.  
  165. DOS!
  166.  
  167. enumeration := Error
  168.  
  169. Example
  170.  
  171. Syntax
  172.  
  173. ([State: enumeration])
  174.  
  175. Description
  176.  
  177. Determine how a macro responds to an Error condition.
  178.  
  179. Create an Error condition with Assert(ErrorCondition!).
  180.  
  181. Return Value
  182.  
  183. Off! Previous state was Off!
  184.  
  185. On! Previous state was On!
  186.  
  187. Parameters
  188.  
  189. State: enumeration (optional)    Specify the Error state. The default is Error(On!). If missing, the current state is returned without changing it.
  190.  
  191. Off! Ignore an Error condition.
  192.  
  193. On! Stop a macro unless preceded by OnError, which directs macro execution to a specified Label.
  194.  
  195. enumeration := ErrorNumber
  196.  
  197. Description
  198.  
  199. Return the error value of a Cancel, Error, Not Found, or user-defined condition.
  200.  
  201. ErrorNumber is a macro system variable that returns an enumeration, which can be referred to by name. The enumerations have the same numeric values as in previous versions. The value of ErrorNumber is cleared before every command. After the command is executed, ErrorNumber returns a value that indicates if an error occurred. If a handler condition is disabled, the macro continues when the specified condition occurs. You can test ErrorNumber manually for ErrorNumber.Success!. Commands that do not reset ErrorNumber are MacroInfo.
  202.  
  203. (ErrorNumber!) calls, ErrorNumber itself, and compound statements, such as If-Endif, Switch-EndSwitch, Repeat-Until, While-EndWhile, For-EndFor, and so on. Copy the value returned by ErrorNumber into a variable if the value is needed after executing other macro commands, such as PROMPT, which reset ErrorNumber.
  204.  
  205. Return Value
  206.  
  207. Success! Formerly value 0.
  208.  
  209. CancelConditionAsserted! Cancel condition was asserted. Formerly value 1.
  210.  
  211. ErrorConditionAsserted! An Error condition was asserted. Formerly value 2.
  212.  
  213. NotFoundConditionAsserted! A Not Found condition was asserted. Formerly value 7.
  214.  
  215. UserDefinedCondition! This value defines the base value for assertions of user-defined conditions. See the Assert command for more information about the value of user-defined condition codes.
  216.  
  217. VarErrChkAsserted! An undefined variable was accessed.
  218.  
  219. enumeration or boolean:= Exists
  220.  
  221. Example
  222.  
  223. Syntax
  224.  
  225. (VariableName: variable; [Pool: enumeration])
  226.  
  227. Description
  228.  
  229. Determine if a variable exists.
  230.  
  231. To exist, a variable must be declared and initialized. Given that variable w is declared and not initialized, and that Local x is initialized to 5, Global y to 10, and Persist z to 15, the following statements are valid:
  232.  
  233. vNoInit := Exists(w)
  234.  
  235. Result: vNoInit equals Exists.NotFound!
  236.  
  237. vLocal := Exists(x)
  238.  
  239. Result: vLocal equals Exists.Local!
  240.  
  241. vGlobal := Exists(y)
  242.  
  243. Result: vGlobal equals Exists.Global!
  244.  
  245. vPersist := Exists(z)
  246.  
  247. Result: vPersist = Exists.Persistent!
  248.  
  249. Examples in shorthand notation
  250.  
  251. If(Exists(vLocal))
  252.  
  253. Beep
  254.  
  255. EndIf
  256.  
  257. Explanation: Computer beeps because Exists returns a value other than Exists.NotFound!.
  258.  
  259. If(Exists(vLocal) = Exists.Persistent!)
  260.  
  261. Beep
  262.  
  263. EndIf
  264.  
  265. Explanation: The computer does not beep because Exists returns Exists.Local!. (vLocal is a Local variable, not a Persist variable.)
  266.  
  267. Return Value
  268.  
  269. If Pool is left off, the values are:
  270.  
  271. NotFound! Variable does not exist.
  272.  
  273. Local! Variable exists in local pool.
  274.  
  275. Global! Variable exists in global pool.
  276.  
  277. Persistent! Variable exists in persistent pool.
  278.  
  279. If Pool is specified, the return value is True (exists in the pool specified by the Pool parameter) or False (does not exist).
  280.  
  281. Parameters
  282.  
  283. VariableName: variable    A variable declared as Local, Global, or Persistent. Variables begin with a letter and can include any other combination of letters or numbers.
  284.  
  285. Pool: enumeration (optional)    If missing, the command returns the Pool the variable is in. If provided, the command returns boolean True or False indicating whether the variable is in the specified Pool.
  286.  
  287. Local! See if the variable exists in the local variable pool.
  288.  
  289. Global! See if the variable exists in the global variable pool.
  290.  
  291. Persistent! See if the variable exists in the persistent variable pool.
  292.  
  293. enumeration := ExitHandlerState
  294.  
  295. Syntax
  296.  
  297. ([State: enumeration])
  298.  
  299. Description
  300.  
  301. Determine how a macro responds to an Exit condition.
  302.  
  303. Create an Exit condition with Assert(ExitCondition!).
  304.  
  305. Unlike Error, Cancel, and NotFound, ExitHandlerState neither enables nor prevents a condition from occurring. It enables or disables calling the exit handler when an exit condition occurs.
  306.  
  307. Return Value
  308.  
  309. Off! Previous state was Off!
  310.  
  311. On! Previous state was On!
  312.  
  313. Parameters
  314.  
  315. State: enumeration (optional)    Specify the Exit state. If missing, the current state is returned without changing it. Default: Exit(On!).
  316.  
  317. Off! Disable exit handler condition calling.
  318.  
  319. On! Enable exit handler condition calling.
  320.  
  321. numeric := ExponentPart
  322.  
  323. Syntax
  324.  
  325. (Value: numeric)
  326.  
  327. Description
  328.  
  329. Return the exponent portion of a numeric value.
  330.  
  331. For example, the exponent of 3.2e18 is 18.
  332.  
  333. Return Value
  334.  
  335. Exponent portion of a numeric value.
  336.  
  337. Parameters
  338.  
  339. Value: numeric    A fractional number (return exponent part of).
  340.  
  341.  
  342.  
  343.  
  344.  
  345.  
  346.