home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 15 Message / 15-Message.zip / oe990925.zip / Rx990924.txt < prev    next >
Text File  |  1999-09-26  |  33KB  |  953 lines

  1.  
  2.                     Programming/using OS/2 REXX      (echo)
  3.  
  4.                  Saturday, 18-Sep-1999 to Friday, 24-Sep-1999
  5.  
  6. +----------------------------------------------------------------------------+
  7.  
  8. From: LEE ARONER                                        17-Sep-99 12:28:00
  9.   To: MURRAY LESSER                                     18-Sep-99 11:24:17
  10. Subj: Boolean boo-boos
  11.  
  12. ML> Excerpted from a message dated 05-31-99, Jack Stein to David Noon:
  13.  
  14.  DN> The LINES() function returns an integer. You were simply
  15.  DN> lucky that the implementation at that time always returned
  16.  DN> an integer that was conformable to Boolean usage: 0 or 1.
  17.  
  18. JS>I still don't understand this as the docs state that the built in
  19.   >function LINES always returns a 1 or a 0, so testing for that seems
  20.   >OK, and works OK as well, both in CREXX and OREXX.  In OREXX, as a
  21.   >method, it returns a 0 or the number of lines remaining, which also
  22.   >should work as it is either 0 (false) or not 0, true.  It is
  23.   >"supposed" to work this way for files or STDIN.
  24.  
  25. ML> Hi Jack--
  26.  
  27. ML>     The only language I am familiar with that will accept any nonzero
  28.   > value as "true" in Boolean expressions is BASIC.  Most certainly, none
  29.  
  30.  
  31.    Murray, obviously I'm reading this months after it was posted, 
  32.    but for the record, Borland's pascal can be made (tricked?) to 
  33.    treat integers as described.
  34.  
  35.                                        LRA
  36.  
  37.  
  38.  -- SPEED 2.01 #2720: == Generic Tagline, good for everyday use ==
  39. --- Platinum Xpress/Win/Wildcat5! v2.0
  40.  * Origin: Memory Alpha - (253) 859-6200 (1:343/311)
  41.  
  42. +----------------------------------------------------------------------------+
  43.  
  44. From: Steve McCrystal                                   17-Sep-99 06:25:09
  45.   To: Eddy Thilleman                                    18-Sep-99 20:11:18
  46. Subj: Classic REXX files?
  47.  
  48. ;
  49. In a msg of <Tuesday September 14 1999>, Eddy Thilleman writes to Jack Stein:
  50. ;
  51. Eddy,
  52.  
  53.  JS>> Why not just put the lines in the startup.cmd?
  54.  
  55.  ET> Then you have to turn the whole startup.cmd file into a REXX file
  56.  ET> (I don't know if that's possible).
  57.  
  58. I tried it, and that is indeed correct. I didn't try to make STARTUP a REXX
  59. file, but just adding the lines certainly doesn't work.  It's simple enough to 
  60. just do a CALL. Thanks!
  61.  
  62. -[Steve]-
  63.  
  64. --- GoldED/2 3.0.1/#
  65.  * Origin: -[Steve's Place]- New Berlin, WI (FidoNet 1:154/731.2)
  66.  
  67. +----------------------------------------------------------------------------+
  68.  
  69. From: Kees Wiegel                                       18-Sep-99 09:38:11
  70.   To: All                                               18-Sep-99 21:50:00
  71. Subj: NoValue condition
  72.  
  73. Hello All,
  74.  
  75. Would someone of you help me out on the following?:
  76.  
  77. In the beginning of a ObjREXX programma I use the clause 'Signal on NoValue'
  78. to trap novalue conditions.
  79.  
  80. Lateron in the same programma I fill an array using the following instruction:
  81.       BLogLines=WL.nn~MakeArray(Line)
  82.  
  83. This causes a novalue condition for the variable LINE in the above clause.
  84.  
  85. How come? How to avoid?
  86.  
  87. Thanks in advance.
  88.  
  89.  
  90. Best Regards,
  91.  
  92. Kees Wiegel, Berkel en Rodenrijs, The Netherlands
  93. SysOp APBCWgl-BronNet
  94.  
  95. ... De chirurg nam de benen.
  96. --- EndOfMsg
  97.  * Origin: APBCWgl-BronNet (FidoNet 2:286/207)
  98.  
  99. +----------------------------------------------------------------------------+
  100.  
  101. From: Jack Stein                                        16-Sep-99 18:32:25
  102.   To: Eddy Thilleman                                    19-Sep-99 10:46:10
  103. Subj: Classic REXX files?
  104.  
  105. Eddy Thilleman wrote in a message to Jack Stein:
  106.  
  107. ET>> Call loadrxx.cmd in your startup.cmd:
  108.  
  109. JS> Why not just put the lines in the startup.cmd?
  110.  
  111.  ET> Then you have to turn the whole startup.cmd file into a REXX
  112.  ET> file (I don't know if that's possible).
  113.  
  114. Sure.  I do it that way here.  If you are calling a rexx script from
  115. startup.cmd, then, why would you not be able to use the start-up to call the
  116. Rexx Utilities?  Hmmm, I guess you are thinking because startup loads before
  117. the WPShell loads?  I don't get any error messages though, so I guess PMShell
  118. is running when startup starts.  The extended utilities don't run w/o PMShell,
  119. WPShell however is meaningless to REXX.
  120.  
  121.                                               Jack 
  122. --- timEd/2-B11
  123.  * Origin: Jack's Free Lunch 4OS2 USR 56k Pgh Pa (412)492-0822 (1:129/171)
  124.  
  125. +----------------------------------------------------------------------------+
  126.  
  127. From: Jack Stein                                        16-Sep-99 18:33:26
  128.   To: Peter Knapper                                     19-Sep-99 10:46:10
  129. Subj: Classic REXX files?
  130.  
  131. Peter Knapper wrote in a message to Eddy Thilleman:
  132.  
  133.  ET> Then you have to turn the whole startup.cmd file into a 
  134.  ET> REXX file (I don't know if that's possible).
  135.  
  136.  PK> Too many external utilties modify STARTUP.CMD expecting it
  137.  PK> to be a standard .CMD file, otherwise there is no problem
  138.  PK> making it into a REXX script. I resolve this issue by adding
  139.  PK>   Call LDREXX.CMD to STARTUP.CMD and place my REXX stuff in 
  140.  PK> LDREXX.
  141.  
  142. I've never had anything modify my startup.cmd file, except me?  I've seen
  143. things modify config.sys, and autoexe.bat in DOS, but never startup.cmd.  
  144.  
  145.                                               Jack 
  146. --- timEd/2-B11
  147.  * Origin: Jack's Free Lunch 4OS2 USR 56k Pgh Pa (412)492-0822 (1:129/171)
  148.  
  149. +----------------------------------------------------------------------------+
  150.  
  151. From: David Noon                                        19-Sep-99 00:00:00
  152.   To: Kees Wiegel                                       19-Sep-99 00:00:00
  153. Subj: NoValue condition
  154.  
  155. In a message dated 09-18-99, Kees Wiegel said to All about "NoValue
  156. condition"
  157.  
  158. Hi Kees,
  159.  
  160. KW>In the beginning of a ObjREXX programma I use the clause 
  161. KW>'Signal on NoValue' to trap novalue conditions.
  162.  
  163. KW>Lateron in the same programma I fill an array using the following
  164. KW>instruction:
  165. KW>      BLogLines=WL.nn~MakeArray(Line)
  166.  
  167. KW>This causes a novalue condition for the variable LINE in the above
  168. KW>clause.
  169.  
  170. KW>How come?
  171.  
  172. The variable LINE has not yet been assigned a value. However, it shouldn't
  173. be a variable in this context.
  174.  
  175. KW>How to avoid?
  176.  
  177. Put LINE in apostrophes or quotes:
  178.  
  179.      BLogLines=WL.nn~MakeArray('Line')
  180.  
  181. It should really be a literal character string.
  182.  
  183. Regards
  184.  
  185. Dave
  186. <Team PL/I>
  187. ___
  188.  * MR/2 2.25 #353 * Redneck: Refers to 5th grade as "My senior year."
  189.  
  190. --- Maximus/2 2.02
  191.  * Origin: OS/2 Shareware BBS, telnet://bbs.os2bbs.com (1:109/347)
  192.  
  193.  
  194. +----------------------------------------------------------------------------+
  195.  
  196. From: Rich Wonneberger                                  19-Sep-99 21:59:00
  197.   To: Eddy Thilleman                                    20-Sep-99 07:46:04
  198. Subj: Classic REXX files?
  199.  
  200. *** Quoting Eddy Thilleman to Rich Wonneberger dated 09-16-99 ***
  201. > Ofcourse you can call any cmd file and any program from startup.cmd!!
  202. > It's just like autoexec.bat for DOS. I'm surprised you didn't know 
  203. > that.
  204.  
  205. I was fairly sure it could..  Just not positive..
  206. After thinking about it the last few days, I decided I should add it to my
  207. system..  Also, I want to open 2 OS/2 windows, and 2 DOS full screen
  208. sessions..  Gota look at the tool bar to see how each are opened..
  209.  
  210. Rich
  211. I-Net   turtil@frontiernet.net
  212.  
  213.  
  214. ... Parking is such street sorrow.  Herb Caen
  215. ---
  216.  * Origin: Turtil's Pond BBS. Monroe NY. 914-783-2106 (1:2625/50)
  217.  
  218. +----------------------------------------------------------------------------+
  219.  
  220. From: Eddy Thilleman                                    17-Sep-99 09:47:25
  221.   To: Peter Knapper                                     20-Sep-99 15:34:27
  222. Subj: Classic REXX files?
  223.  
  224. Hello Peter,
  225.  
  226. 16 Sep 99 11:39, Peter Knapper wrote to Eddy Thilleman:
  227.  
  228. ET>> Then you have to turn the whole startup.cmd file into a
  229. ET>> REXX file (I don't know if that's possible).
  230.  
  231. PK> Too many external utilties modify STARTUP.CMD expecting it to be a
  232. PK> standard .CMD file,
  233.  
  234. I've never seen a program that modified or looked at STARTUP.CMD.
  235.  
  236. PK> otherwise there is no problem making it into a
  237. PK> REXX script.
  238.  
  239. I haven't tried it.
  240.  
  241. PK> I resolve this issue by adding - Call LDREXX.CMD to
  242. PK> STARTUP.CMD and place my REXX stuff in LDREXX.
  243.  
  244. That's what I said earlier.
  245.  
  246.   Greetings   -=Eddy=-        email: eddy.thilleman@net.hcc.nl
  247.  
  248. ... (-*-) <-- Darth Tribble in his TIE fighter
  249. --- GoldED/2 3.0.1
  250.  * Origin: Windows95 is a graphic DOS extender (2:500/143.7)
  251.  
  252. +----------------------------------------------------------------------------+
  253.  
  254. From: MIKE RUSKAI                                       19-Sep-99 22:32:00
  255.   To: KEES WIEGEL                                       20-Sep-99 20:42:18
  256. Subj: NoValue condition
  257.  
  258. Some senseless babbling from Kees Wiegel to All
  259. on 09-18-99  09:38 about NoValue condition...
  260.  
  261.  KW> Hello All,
  262.  
  263.  KW> Would someone of you help me out on the following?:
  264.  
  265.  KW> In the beginning of a ObjREXX programma I use the clause 'Signal on
  266.  KW> NoValue' to trap novalue conditions.
  267.  
  268.  KW> Lateron in the same programma I fill an array using the following
  269.  KW> instruction: BLogLines=WL.nn~MakeArray(Line)
  270.  
  271.  KW> This causes a novalue condition for the variable LINE in the above
  272.  KW> clause. 
  273.  KW> How come? How to avoid?
  274.  
  275.  KW> Thanks in advance.
  276.  
  277. With only that to go by, the only conclusion one can draw is that you've 
  278. not assigned a value to the variable LINE.
  279.  
  280. Mike Ruskai
  281. thannymeister@yahoo.com
  282.  
  283.  
  284. ... Had to give away the kids - The cat got allergic.
  285.  
  286. ___ Blue Wave/QWK v2.20
  287. --- Platinum Xpress/Win/Wildcat5! v3.0pr2
  288.  * Origin: FIDO QWK MAIL & MORE!  WWW.DOCSPLACE.ORG (1:3603/140)
  289. 267/200
  290.  
  291. +----------------------------------------------------------------------------+
  292.  
  293. From: David Bowerman                                    20-Sep-99 17:25:28
  294.   To: Kees Wiegel                                       21-Sep-99 07:57:16
  295. Subj: NoValue condition
  296.  
  297. Kees Wiegel wrote in a message to All:
  298.  
  299.  KW> In the beginning of a ObjREXX programma I use the clause 'Signal on
  300.  KW> NoValue' to trap novalue conditions.
  301.  
  302.  KW> Lateron in the same programma I fill an array using the following
  303.  KW> instruction:       BLogLines=WL.nn~MakeArray(Line)
  304.  
  305.  KW> This causes a novalue condition for the variable LINE in the above
  306.  KW> clause. 
  307.  
  308.  KW> How come? How to avoid?
  309.  
  310. What does the line where you assign a value to the variable LINE look like? 
  311. If there is no assignment, LINE has no value and the trap is correct.
  312.  
  313. Regards,
  314.        David
  315.  
  316. --- timEd/2 1.10.y2k+
  317.  * Origin:  Frog Hollow -- a scenic backroad off the Infobahn (1:153/290)
  318.  
  319. +----------------------------------------------------------------------------+
  320.  
  321. From: Steve McCrystal                                   20-Sep-99 06:33:22
  322.   To: Jack Stein                                        21-Sep-99 15:22:24
  323. Subj: Classic REXX files?
  324.  
  325. ;
  326. In a msg of <Thursday September 16 1999>, Jack Stein writes to Eddy Thilleman:
  327. ;
  328. Jack,
  329.  
  330.  ET>> Then you have to turn the whole startup.cmd file into a REXX
  331.  ET>> file (I don't know if that's possible).
  332.  
  333.  JS> Sure.  I do it that way here.  If you are calling a rexx script
  334.  JS> from startup.cmd, then, why would you not be able to use the
  335.  JS> start-up to call the Rexx Utilities?
  336.  
  337. I'm not sure *why* it doesn't work, but I got error messages (unknown function 
  338. in line xx, as I recall) when I added the lines to startup.  When I CALLed the 
  339. same lines in a seperate script, it worked.  I left it that way! :^)
  340.  
  341. -[Steve]-
  342.  
  343. --- GoldED/2 3.0.1/#
  344.  * Origin: -[Steve's Place]- New Berlin, WI (FidoNet 1:154/731.2)
  345.  
  346. +----------------------------------------------------------------------------+
  347.  
  348. From: Eddy Thilleman                                    20-Sep-99 20:06:26
  349.   To: Mike Ruskai                                       21-Sep-99 19:35:23
  350. Subj: Classic REXX files?
  351.  
  352. Hello Mike,
  353.  
  354. 16 Sep 99 12:42, MIKE RUSKAI wrote to EDDY THILLEMAN:
  355.  
  356. ET>>> Call loadrxx.cmd in your startup.cmd:
  357.  
  358. JS>> Why not just put the lines in the startup.cmd?
  359.  
  360. ET>> Then you have to turn the whole startup.cmd file into a REXX file
  361. ET>> (I don't know if that's possible).
  362.  
  363. MR> It certainly is.
  364.  
  365. OK, thanks for the comment. :)
  366.  
  367.   Greetings   -=Eddy=-        email: eddy.thilleman@net.hcc.nl
  368.  
  369. ... "We're having an adventure, just like the Goonies!" -- Crow
  370. --- GoldED/2 3.0.1
  371.  * Origin: Windows98 is a graphic DOS extender (2:500/143.7)
  372.  
  373. +----------------------------------------------------------------------------+
  374.  
  375. From: Eddy Thilleman                                    20-Sep-99 20:10:19
  376.   To: Steve Mccrystal                                   21-Sep-99 19:35:23
  377. Subj: Classic REXX files?
  378.  
  379. Hello Steve,
  380.  
  381. 17 Sep 99 06:25, Steve McCrystal wrote to Eddy Thilleman:
  382.  
  383. JS>>> Why not just put the lines in the startup.cmd?
  384.  
  385. ET>> Then you have to turn the whole startup.cmd file into a REXX file
  386. ET>> (I don't know if that's possible).
  387.  
  388. SM> I tried it, and that is indeed correct. I didn't try to make STARTUP a
  389. SM> REXX file, but just adding the lines certainly doesn't work.
  390.  
  391. A .cmd file can only be _or_ a normal batch file _or_ a REXX file, and never
  392. both.
  393.  
  394. SM> It's simple enough to just do a CALL. Thanks!
  395.  
  396. That's what I do. :)
  397.  
  398.   Greetings   -=Eddy=-        email: eddy.thilleman@net.hcc.nl
  399.  
  400. ... Here I sit, in a tizzy; all my favorite boards are busy
  401. --- GoldED/2 3.0.1
  402.  * Origin: Windows95 is a graphic DOS extender (2:500/143.7)
  403.  
  404. +----------------------------------------------------------------------------+
  405.  
  406. From: Eddy Thilleman                                    20-Sep-99 20:16:21
  407.   To: Jack Stein                                        21-Sep-99 19:35:23
  408. Subj: Classic REXX files?
  409.  
  410. Hello Jack,
  411.  
  412. 16 Sep 99 18:32, Jack Stein wrote to Eddy Thilleman:
  413.  
  414. JS> Eddy Thilleman wrote in a message to Jack Stein:
  415.  
  416. ET>>> Call loadrxx.cmd in your startup.cmd:
  417.  
  418. JS>> Why not just put the lines in the startup.cmd?
  419.  
  420. ET>> Then you have to turn the whole startup.cmd file into a REXX
  421. ET>> file (I don't know if that's possible).
  422.  
  423. JS> Sure.  I do it that way here.
  424.  
  425. Then you start your startup.cmd file with a REXX comment?
  426.  
  427. JS> If you are calling a rexx script from startup.cmd, then, why would you
  428. JS> not be able to use the start-up to call the Rexx Utilities?
  429.  
  430. That's what I do: I call a REXX file from my startup.cmd.
  431.  
  432. Thinking about startup.cmd: startup.cmd is just a normal batch file and REXX
  433. uses also text files with the .cmd extension (because of the command
  434. processor), so now I see how you can think of making startup.cmd a REXX file.
  435. :)
  436.  
  437. JS> Hmmm, I guess you are thinking because startup loads before the
  438. JS> WPShell loads?
  439.  
  440. No, I just hadn't thought about making my startup.cmd file into a REXX file.
  441.  
  442. JS> I don't get any error messages though, so I guess PMShell is running
  443. JS> when startup starts.
  444.  
  445. At the time startup.cmd starts, the screen is already a blank graphic screen,
  446. that's Program Manager (PM).
  447.  
  448.   Greetings   -=Eddy=-        email: eddy.thilleman@net.hcc.nl
  449.  
  450. ... Windows, or how to turn your 80486 into an 8088....
  451. --- GoldED/2 3.0.1
  452.  * Origin: Windows95 is a graphic DOS extender (2:500/143.7)
  453.  
  454. +----------------------------------------------------------------------------+
  455.  
  456. From: Tobias Ernst                                      20-Sep-99 08:25:01
  457.   To: Jack Stein                                        22-Sep-99 03:20:18
  458. Subj: Classic REXX files?
  459.  
  460. Hallo Jack!
  461.  
  462.  JS> -+- timEd/2-B11
  463.  
  464. Because of Y2K, you should definitely upgrade to timEd/2 1.10 and apply the
  465. Artfix05 fix package. All the files you need are at
  466. http://www.phycip.uni-stuttgart.de/tobi/projects.html#artfix
  467.  
  468. Viele Grⁿ▀e,
  469. Tobias
  470.  
  471. --- Msged/BSD TE 06 (pre)
  472.  * Origin: Running FreeBSD 3.2 (2:2476/418)
  473.  
  474. +----------------------------------------------------------------------------+
  475.  
  476. From: MIKE RUSKAI                                       21-Sep-99 18:56:00
  477.   To: DAVID BOWERMAN                                    22-Sep-99 06:57:06
  478. Subj: NoValue condition
  479.  
  480. Some senseless babbling from David Bowerman to Kees Wiegel
  481. on 09-20-99  17:25 about NoValue condition...
  482.  
  483.  DB> Kees Wiegel wrote in a message to All:
  484.  
  485.  KW> In the beginning of a ObjREXX programma I use the clause 'Signal on
  486.  KW> NoValue' to trap novalue conditions.
  487.  
  488.  KW> Lateron in the same programma I fill an array using the following
  489.  KW> instruction:       BLogLines=WL.nn~MakeArray(Line)
  490.  
  491.  KW> This causes a novalue condition for the variable LINE in the above
  492.  KW> clause. 
  493.  
  494.  KW> How come? How to avoid?
  495.  
  496.  DB> What does the line where you assign a value to the variable LINE look
  497.  DB> like?  If there is no assignment, LINE has no value and the trap is
  498.  DB> correct. 
  499.  
  500. I recently looked at the OREXX docs to figure out just when the makearray 
  501. method is supposed to take an argument, and it's only when creating an 
  502. array from a stream object.  The only two valid arguments are 'LINES' and 
  503. 'CHARS'.  It will, however, work for any subtring of each argument.  So, 
  504. his code will work, but trigger the NOVALUE condition.  To not trigger it, 
  505. he must enclose it in quotes, making it an explicit string, rather than an 
  506. implicit string (after all other evaluations of the symbol fail).
  507.  
  508. Mike Ruskai
  509. thannymeister@yahoo.com
  510.  
  511.  
  512. ... Bring out your dead. <KLANK>  Bring out your dead.
  513.  
  514. ___ Blue Wave/QWK v2.20
  515. --- Platinum Xpress/Win/Wildcat5! v3.0pr2
  516.  * Origin: FIDO QWK MAIL & MORE!  WWW.DOCSPLACE.ORG (1:3603/140)
  517. 267/200
  518. 45
  519.  
  520. +----------------------------------------------------------------------------+
  521.  
  522. From: David Bowerman                                    21-Sep-99 23:30:27
  523.   To: Steve McCrystal                                   22-Sep-99 06:57:06
  524. Subj: Classic REXX files?
  525.  
  526. Steve McCrystal wrote in a message to Jack Stein:
  527.  
  528.  JS> Sure.  I do it that way here.  If you are calling a rexx script
  529.  JS> from startup.cmd, then, why would you not be able to use the
  530.  JS> start-up to call the Rexx Utilities?
  531.  
  532.  SM> I'm not sure *why* it doesn't work, but I got error messages
  533.  SM> (unknown function in line xx, as I recall) when I added the lines
  534.  SM> to startup.  When I CALLed the same lines in a seperate script, it
  535.  SM> worked.  I left it that way! :^) 
  536.  
  537. Did you add the initial "/* blah de blah */" comment starting on the first
  538. column of the first line?  Minus the ""s of course.  Without that comment, the 
  539. file will be sent to the command interpreter which is going to have trouble
  540. attempting to make sense of a REXX file.
  541.  
  542. Of course, I know this simply from reading the manual. <wry grin>
  543.  
  544. Regards,
  545.        David
  546.  
  547. --- timEd/2 1.10.y2k+
  548.  * Origin:  Frog Hollow -- a scenic backroad off the Infobahn (1:153/290)
  549.  
  550. +----------------------------------------------------------------------------+
  551.  
  552. From: Kees Wiegel                                       21-Sep-99 16:39:23
  553.   To: David Noon                                        22-Sep-99 13:53:26
  554. Subj: NoValue condition
  555.  
  556. Hello David,
  557.  
  558. Sunday September 19 1999 00:00, David Noon wrote to Kees Wiegel:
  559.  
  560.  DN> The variable LINE has not yet been assigned a value. However, it
  561.  DN> shouldn't be a variable in this context.
  562.  
  563.  DN> It should really be a literal character string.
  564.  
  565. Bingo! I completely overlooked that.
  566. Thank you for helping out.
  567.  
  568.  
  569. Best Regards,
  570.  
  571. Kees Wiegel, Berkel en Rodenrijs, The Netherlands
  572. SysOp APBCWgl-BronNet
  573.  
  574. ... Soon to be released: 32-bits EdLin for Windows 95!
  575. --- EndOfMsg
  576.  * Origin: APBCWgl-BronNet (FidoNet 2:286/207)
  577.  
  578. +----------------------------------------------------------------------------+
  579.  
  580. From: Eddy Thilleman                                    21-Sep-99 09:27:17
  581.   To: Rich Wonneberger                                  22-Sep-99 20:42:19
  582. Subj: Classic REXX files?
  583.  
  584. Hello Rich,
  585.  
  586. 19 Sep 99 21:59, Rich Wonneberger wrote to Eddy Thilleman:
  587.  
  588. RW> After thinking about it the last few days, I decided I should add it
  589. RW> to my system..  Also, I want to open 2 OS/2 windows, and 2 DOS full
  590. RW> screen sessions..  Gota look at the tool bar to see how each are
  591. RW> opened..
  592.  
  593. see the text about the start command in CMDREF.INF:
  594. /win for windowed session
  595. /fs  for fullscreen session
  596. /f   for foreground
  597. /b   for background
  598. /dos for DOS session
  599.  
  600.   Greetings   -=Eddy=-        email: eddy.thilleman@net.hcc.nl
  601.  
  602. ... Screw the Prime Directive - inflict Windows on the Borg!
  603. --- GoldED/2 3.0.1
  604.  * Origin: Windows98 is a graphic DOS extender (2:500/143.7)
  605.  
  606. +----------------------------------------------------------------------------+
  607.  
  608. From: Eddy Thilleman                                    21-Sep-99 23:41:04
  609.   To: All                                               22-Sep-99 20:42:19
  610. Subj: hstart wget?
  611.  
  612. Hello All,
  613.  
  614. I made a REXX file wgetmir.cmd to read all the lines in a textfile which are
  615. the websites or files on internet to retrieve with wget. wget is running OK
  616. when hstarted from a command line or a plain batch file, but not from the REXX 
  617. file (no screen output or no log file if log file is specified). Does someone
  618. spot what I'm doing wrong?
  619.  
  620. ------------------- begin of wgetmir.cmd -------------------
  621. /* start wget mirroring each website/file listed in wget.mir */
  622. arg InFile
  623.  
  624. if InFile = '' then
  625.   InFile = 'wget.mir'
  626.  
  627. '@echo off'
  628. dir = directory( 'c:\www' )
  629. 'set wgetrc=c:\www\wget.cfg'
  630.  
  631. dquote = d2c(34)  /* " double quote character */
  632. squote = d2c(39)  /* ' single quote character */
  633. cmd1 = ' wget -m -c -nc -np -Q1m --tries=1 -k -w1 '
  634. cmd2 = ' -a wgetmir'
  635. cmd3 = '.log>nul'
  636.  
  637. signal on notready
  638.  
  639. LineNr = 0
  640.  
  641. LineIn( InFile, 1, 0 )
  642.    /* No read; opens inputfile */
  643.    /* (if file is already open, sets the read position to the first line). */
  644.  
  645. do while Lines( InFile ) > 0
  646.   Line = LineIn( InFile )
  647.   LineNr = LineNr + 1
  648.   say LineNr': 'Line
  649.   cmd = cmd1||Line||cmd2||LineNr||cmd3
  650.   "hstart /win /c b " cmd
  651. end
  652.  
  653. exit
  654.  
  655. NotReady:
  656.   if LineNr = 0 then
  657.     say 'could not open 'InFile
  658.  
  659. exit
  660. -------------------- end of wgetmir.cmd --------------------
  661.  
  662.   Greetings   -=Eddy=-        email: eddy.thilleman@net.hcc.nl
  663.  
  664. ... WindowError:019 User error.  It's not our fault.  Is not!  Is not!
  665. --- GoldED/2 3.0.1
  666.  * Origin: Windows95 is a graphic DOS extender (2:500/143.7)
  667.  
  668. +----------------------------------------------------------------------------+
  669.  
  670. From: Rich Wonneberger                                  22-Sep-99 22:17:00
  671.   To: Eddy Thilleman                                    23-Sep-99 07:00:12
  672. Subj: Classic REXX files?
  673.  
  674. *** Quoting Eddy Thilleman to Rich Wonneberger dated 09-21-99 ***
  675. > see the text about the start command in CMDREF.INF:
  676. > /win for windowed session
  677.  
  678. Thanks Eddy.
  679. I didnt look in it yet, but the help has it also for START command.  This
  680. weekend I will tinker with it a bit.
  681.  
  682. Rich
  683. I-Net   turtil@frontiernet.net
  684.  
  685.  
  686. ... C program run. C program crash. C programmer get drunk.
  687. ---
  688.  * Origin: Turtil's Pond BBS. Monroe NY. 914-783-2106 (1:2625/50)
  689.  
  690. +----------------------------------------------------------------------------+
  691.  
  692. From: Eddy Thilleman                                    22-Sep-99 16:25:02
  693.   To: Steve Mccrystal                                   24-Sep-99 06:16:06
  694. Subj: Classic REXX files?
  695.  
  696. Hello Steve,
  697.  
  698. 20 Sep 99 06:33, Steve McCrystal wrote to Jack Stein:
  699.  
  700. JS>> Sure.  I do it that way here.  If you are calling a rexx script
  701. JS>> from startup.cmd, then, why would you not be able to use the
  702. JS>> start-up to call the Rexx Utilities?
  703.  
  704. SM> I'm not sure *why* it doesn't work, but I got error messages (unknown
  705. SM> function in line xx, as I recall) when I added the lines to startup.
  706. SM> When I CALLed the same lines in a seperate script, it worked.  I left
  707. SM> it that way! :^)
  708.  
  709. If you add REXX code to a plain batch file then that batch is not a REXX file
  710. that can be run, you have to turn the whole batch file into a REXX file: on
  711. the first line in the first column the batch file must start with a comment,
  712. to begin with.
  713.  
  714. Why don't you post here what you made out of it, so we could take a look at
  715. it?
  716.  
  717.   Greetings   -=Eddy=-        email: eddy.thilleman@net.hcc.nl
  718.  
  719. ... WindowError:001 Windows loaded.  System in danger.
  720. --- GoldED/2 3.0.1
  721.  * Origin: Windows98 is a graphic DOS extender (2:500/143.7)
  722.  
  723. +----------------------------------------------------------------------------+
  724.  
  725. From: Eddy Thilleman                                    22-Sep-99 16:36:26
  726.   To: All                                               24-Sep-99 06:16:06
  727. Subj: hstart wget?
  728.  
  729. Hoi!
  730.  
  731. I've it working. :) It turned out to be the result of a limitation of wget:
  732. wget cannot 'timestamp' and 'not clobber' files at the same time.
  733.  
  734. I had timestamping = on in wget.cfg and used the -nc (no clobber) parameter at 
  735. the same time.
  736.  
  737. I had for each wget a logfile specified, it surprised me that wget doesn't
  738. create the logfile because of this error (so I didn't see this error because
  739. the sessions were closed).
  740.  
  741. ------------------- begin of wget.cfg -------------------
  742. continue = on
  743. convert_links = on
  744. dirstruct = on
  745. quota = 1m
  746. tries = 5
  747. follow_ftp = on
  748. timestamping = on
  749. -------------------- end of wget.cfg --------------------
  750.  
  751.  
  752. --------------------- begin of wgetmir.cmd ---------------------
  753. /* start wget mirroring each website/file listed in wget.mir */
  754. arg InFile
  755.  
  756. if InFile = '' then
  757.   InFile = 'wget.mir'
  758.  
  759. dir = directory( 'c:\www' )
  760. 'set wgetrc=c:\www\wget.cfg'
  761.  
  762. cmd1 = 'wget.exe -m -c -np --tries=1 -k -w1 '
  763. cmd2 = ' -a wgetmir'
  764. cmd3 = '.log'
  765.  
  766. signal on notready
  767.  
  768. LineNr = 0
  769.  
  770. LineIn( InFile, 1, 0 )
  771.   /* No read; opens inputfile */
  772.   /* (if file is already open, sets the read position to the first line). */
  773.  
  774. do while Lines( InFile ) > 0
  775.   Line = LineIn( InFile )
  776.   LineNr = LineNr + 1
  777.   say LineNr': 'Line
  778.   cmd = cmd1||Line||cmd2||LineNr||cmd3
  779.   "@hstart /win /c /b "cmd">nul"
  780. end
  781.  
  782. exit
  783.  
  784. NotReady:
  785.   if LineNr = 0 then
  786.     say 'could not open 'InFile
  787.  
  788. exit
  789. --------------------- end of wgetmir.cmd ---------------------
  790.  
  791. For each line in wget.mir a separate wget-task is started, all running at the
  792. same time. This way, next lines won't have to wait until files on previous
  793. lines are complete.
  794.  
  795. I stopped using RxFTP because wget is much more capable: wget can pick up
  796. where a previous download of a file was not complete, mirroring, etc.
  797.  
  798.   Greetings   -=Eddy=-        email: eddy.thilleman@net.hcc.nl
  799.  
  800. ... "Windows NT Performance", on the next "In Search Of"
  801. --- GoldED/2 3.0.1
  802.  * Origin: Windows98 is a graphic DOS extender (2:500/143.7)
  803.  
  804. +----------------------------------------------------------------------------+
  805.  
  806. From: Jack Stein                                        22-Sep-99 08:03:17
  807.   To: Steve Mccrystal                                   24-Sep-99 10:24:12
  808. Subj: Classic REXX files?
  809.  
  810. Steve Mccrystal wrote in a message to Jack Stein:
  811.  
  812.  ET>> Then you have to turn the whole startup.cmd file into a REXX
  813.  ET>> file (I don't know if that's possible).
  814.  
  815.  JS> Sure.  I do it that way here.  If you are calling a rexx script
  816.  JS> from startup.cmd, then, why would you not be able to use the
  817.  JS> start-up to call the Rexx Utilities?
  818.  
  819.  SM> I'm not sure *why* it doesn't work, but I got error messages
  820.  SM> (unknown function in line xx, as I recall) when I added the
  821.  SM> lines to startup.  When I CALLed the same lines in a
  822.  SM> seperate script, it worked.  I left it that way! :^) 
  823.  
  824. Either you did not turn your STARTUP.CMD into a REXX script, or, you turned it 
  825. into a REXX script, but had normal batch language (syntax) in the script.  
  826.  
  827. The first thing OS/2 does is determine if the script is regular cmd file, or,
  828. a REXX script, it knows this by the very first line at position 0,0 in the
  829. file.  If it is a comment, then what follows MUST be REXX code, using REXX
  830. syntax.  If your script is a REXX script, then you can start the REXX Extended 
  831. Utilities from the startup.cmd file, as well as use any other REXX commands.  
  832.  
  833. You can also use any regular batch commands, but you must use proper quoting
  834. so REXX knows what is meant as literals to be passed to cmd.exe, and what are
  835. internal instructions to to REXX.
  836.  
  837. For example, to load my 4OS2 alias file a regular cmd file would have:
  838.  
  839. ALIAS /r e:\4os2301\os2alias
  840.  
  841. REXX has no clue what "ALIAS" is, so he passes ALIAS to CMD.EXE.  The
  842. paramaters however are very confusing to REXX, since it recognizes some of the 
  843. symbols, such as "/", and "\".  Because of this, you must quote the parameters 
  844. so REXX doesn't try to divide something by r, for example, so the line looks
  845. like this in a REXX script:
  846.  
  847. ALIAS '/r e:\4os2301\os2alias'
  848.  
  849. Also, to make a directory, the same thing applies:
  850.  
  851. md "z:\xpress"
  852.  
  853. You have to understand this enough so you can use REXX fully, and the
  854. STARTUP.CMD file is no different than any other REXX script. 
  855.  
  856.  In short, it's OK not to start up the extended utilities in your startup.cmd, 
  857. but it's not OK to not know why you got the errors.:-) 
  858.                
  859.                                Jack 
  860. --- timEd/2-B11
  861.  * Origin: Jack's Free Lunch 4OS2 USR 56k Pgh Pa (412)492-0822 (1:129/171)
  862.  
  863. +----------------------------------------------------------------------------+
  864.  
  865. From: Jack Stein                                        22-Sep-99 08:34:02
  866.   To: Eddy Thilleman                                    24-Sep-99 10:24:12
  867. Subj: Classic REXX files?
  868.  
  869. Eddy Thilleman wrote in a message to Jack Stein:
  870.  
  871. ET>>> Call loadrxx.cmd in your startup.cmd:
  872.  
  873. JS>> Why not just put the lines in the startup.cmd?
  874.  
  875. ET>> Then you have to turn the whole startup.cmd file into a REXX
  876. ET>> file (I don't know if that's possible).
  877.  
  878. JS> Sure.  I do it that way here.
  879.  
  880.  ET> Then you start your startup.cmd file with a REXX comment?
  881.  
  882. Yes, one can't call REXX functions from a batch file, right?
  883.  
  884. JS> If you are calling a rexx script from startup.cmd, then, why 
  885. JS> would you not be able to use the start-up to call the Rexx 
  886. JS> Utilities?
  887.  
  888.  ET> That's what I do: I call a REXX file from my startup.cmd.
  889.  
  890. That's OK too, but not necessary if your startup.cmd is a REXX file.
  891.  
  892.  ET> Thinking about startup.cmd: startup.cmd is just a normal
  893.  ET> batch file and REXX uses also text files with the .cmd
  894.  ET> extension (because of the command processor), so now I see
  895.  ET> how you can think of making startup.cmd a REXX file. :) 
  896.  
  897. Yep, but you must understand how to use regular batch commands in a REXX
  898. script if you are also mixing in regular batch commands.  This is part of
  899. knowing how to use REXX, so the concepts are important either way.  
  900.  
  901. JS> Hmmm, I guess you are thinking because startup loads before the
  902. JS> WPShell loads?
  903.  
  904.  ET> No, I just hadn't thought about making my startup.cmd file
  905.  ET> into a REXX file. 
  906.  
  907. JS> I don't get any error messages though, so I guess PMShell is running
  908. JS> when startup starts.
  909.  
  910.  ET> At the time startup.cmd starts, the screen is already a
  911.  ET> blank graphic screen, that's Program Manager (PM).
  912.  
  913. I remember long ago people used to say REXX didn't work w/o PMShell, but that
  914. is wrong, it works fine w/o PMShell, but the extended utilities don't work w/o 
  915. PMShell.  Not many people run OS/2 w/o the "windows" shell, even hard core
  916. windows haters like me.  Too much stuff depends on PMShell to be bothered
  917. avoiding it completly, so I learned to live with it.
  918.  
  919.                                               Jack 
  920. --- timEd/2-B11
  921.  * Origin: Jack's Free Lunch 4OS2 USR 56k Pgh Pa (412)492-0822 (1:129/171)
  922.  
  923. +----------------------------------------------------------------------------+
  924.  
  925. From: Jack Stein                                        22-Sep-99 08:50:10
  926.   To: Tobias Ernst                                      24-Sep-99 10:24:12
  927. Subj: Classic REXX files?
  928.  
  929. Tobias Ernst wrote in a message to Jack Stein:
  930.  
  931.  TE> Hallo Jack!
  932.  
  933.  JS> -+- timEd/2-B11
  934.  
  935.  TE> Because of Y2K, you should definitely upgrade to timEd/2
  936.  TE> 1.10 and apply the Artfix05 fix package. All the files you
  937.  TE> need are at
  938.  
  939.  TE> http://www.phycip.uni-stuttgart.de/tobi/projects.html#artfix
  940.  
  941. Thanks Tobias, I'll have to give it a look.  I have far more problems than
  942. just the off-line reader though, my BBS dies on Y2K, so I have to either quit, 
  943. or change BBS systems.  I don't feel like doing either, so who knows where
  944. I'll be on 1/1/00.  I guess I'll switch to MAX/2 if I get the energy.
  945.  
  946.                                               Jack 
  947. --- timEd/2-B11
  948.  * Origin: Jack's Free Lunch 4OS2 USR 56k Pgh Pa (412)492-0822 (1:129/171)
  949.  
  950. +----------------------------------------------------------------------------+
  951.  
  952. +============================================================================+
  953.