home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Professional Developers Kit 1992 November / Disc01 / Disc01.mdf / os2bbs / os2rexx.cfo < prev    next >
Encoding:
Text File  |  1992-10-31  |  334.7 KB  |  8,622 lines

  1.  
  2.  This forum is supplied for demonstration purposes only and is
  3.  accessible via the IBM OS/2 BBS system.  What you see below is the
  4.  forum as it existed on 10/30/92.  The IBM OS/2 Bulletin Board System
  5.  (BBS) is IBM's new electronic support offering for OS/2 Version 2.0.
  6.  With OS/2 BBS you can electronically review OS/2 technical
  7.  information, submit program defects to IBM, and receive information
  8.  on how to solve problems.  Users of the OS/2 BBS not only include
  9.  OS/2 customers, but the OS/2 expertise of the entire internal IBM
  10.  community worldwide.  OS2BBS makes all this available via a local
  11.  or toll free number in most major cities.
  12.  
  13.  To request a complete OS/2 BBS Information Package detailing
  14.  the OS/2 BBS offering and including pricing and registration/access
  15.  information, please call:  1-800-547-1283.
  16.  
  17. ===== OS2REXX CFORUM created at 01:49:24 on 92/04/08 GMT (by HOPKINS at AUSVM8)
  18.                             IBM UNCLASSIFIED
  19.                             ----------------
  20.       The information in this forum is considered by IBM to be
  21.       external and may be shared by everyone who is given access.
  22.       This forum is shared with the internal IBM employee conferences.
  23.  
  24. Forum: OS2REXX CFORUM
  25.  
  26. Forum subject: Procedures Language/2 REXX for OS/2
  27.  
  28.             This FORUM is provided as a conferencing tool to promote
  29.             discussion on topics related to Procedures Language/2 REXX
  30.             for OS/2, and present issues, questions, or problems related
  31.             to the use of REXX for OS/2.
  32.             A new, 32-bit Procedures Language/2 REXX is included with
  33.             OS/2 2.0.  It is significantly faster than the previous
  34.             16-bit version shipped in OS/2 1.3 and includes online
  35.             documentation.  New REXX utilities functions provide better
  36.             access to system services such as the Workplace Shell.
  37.  
  38. Contributions must not contain confidential or proprietary information.
  39.  
  40. Each contributor agrees, in placing material in this forum, that IBM and
  41. other users are free to prepare derivative works based upon it, and to use,
  42. reproduce, perform, display and distribute inside and outside their company
  43. such material and such derivative works, without obligation or charge.
  44.  
  45. IBM is not responsible or liable for the use, copying, or distribution of
  46. materials placed on this forum, and has therefore no obligation to control
  47. such acts.
  48.  
  49. All subscribers are required to abide at all times by the conference
  50. rules described in the Bulletin Board Rules under "News and Announcements".
  51.  
  52. All IBM personnel are required to abide at all times by the IBMPC RULES
  53. and the IBM Business Conduct Guidelines. IBM personnel will read the
  54. CUSTOMER FORUM RULES in IBMPC RULES before contributing.
  55.  
  56. Contributions violating these rules will be deleted by the CFORUM
  57. Owner or their delegate, and in some cases by an IBM conference
  58. Administrator.
  59.  
  60. The OS2BBS CFORUM is where anyone may raise concerns regarding rules
  61. violations found in this and other CFORUMS.
  62.  
  63.    The IBM Owner of this forum is:
  64.    Name:            Kenneth M. Hopkins, OS/2 Support Services
  65.    Mailing Address: IBM Manufacturing and Development
  66.                     11400 Burnet Road
  67.                     Internal Zip 2900-042/1D003
  68.                     Austin, Texas    78758
  69.    IBM Node/Userid: AUSVM8/HOPKINS
  70.  
  71. ----- OS2REXX CFORUM appended at 11:57:54 on 92/05/04 GMT (by DDM at GYSVMHD1)
  72. Subject: EXECIO
  73. Ref: None
  74.  
  75. Is there an OS/2 Rexx equivalent for EXECIO on VM?
  76.  
  77. David D. Miller
  78. European Networking Centre, Heidelberg, Germany
  79.  
  80. ----- OS2REXX CFORUM appended at 12:32:24 on 92/05/04 GMT (by MIR at UKFSCXA) -
  81. Subject: EXECIO
  82. Ref:     Append at 11:57:54 on 92/05/04 GMT (by DDM at GYSVMHD1)
  83.  
  84. No, you have to use linein and lineout.
  85.  
  86. Martin Packer
  87. IBM UK
  88.  
  89. ----- OS2REXX CFORUM appended at 13:26:16 on 92/05/04 GMT (by PMUELLR at CARVM3)
  90. ..... OS2REXX CFORUM modified at 13:32:52 on 92/05/04 GMT (by PMUELLR at CARVM3)
  91. Subject: EXECIO
  92. Ref:     Append at 11:57:54 on 92/05/04 GMT (by DDM at GYSVMHD1)
  93.  
  94. Linein() and Lineout() are probably the best way to go, but you can
  95. do something like
  96.  
  97.    "DIR | RXQUEUE"
  98.  
  99. and the output of the DIR command will be placed in the queue.  To
  100. put the contents of a file in the queue, you can do a
  101.  
  102.    "TYPE C:\CONFIG.SYS | RXQUEUE"
  103.  
  104. It's documented in the hardcopy 2.0 rexx reference in Chapter 12.  I
  105. can't seem to find it in the online rexx help though ("VIEW REXX").
  106. It's also going to be slower than using linein() and lineout() since
  107. OS/2 has to start up a few processes, and buffer the input a few times.
  108. Also, there is no way to take something on the queue and have it piped
  109. to an OS/2 process (the equivalent of EXECIO x DISKW ...).
  110.  
  111. Patrick Mueller - IBM Cary
  112.  
  113. ----- OS2REXX CFORUM appended at 20:03:05 on 92/05/05 GMT (by AACL0X7 at OS2CUST)
  114. Subject: EXECIO
  115. Ref: Append at 13:26:16 on 92/05/04 GMT (by PMUELLR at CARVM3)
  116.  
  117. But remember when piping output through RXQUEUE that you lose access to
  118. any return code from the command.  It's usually better to redirect
  119. output to a file and use linein() than RXQUEUE.
  120.  
  121. ----- OS2REXX CFORUM appended at 21:05:30 on 92/05/05 GMT (by PMUELLR at CARVM3)
  122. Subject: EXECIO
  123. Ref:     Append at 20:03:05 on 92/05/05 GMT (by AACL0X7 at OS2CUST)
  124.  
  125. True, but if you don't care about the return code, it's easier to
  126. bypass the file altogether (so you don't have to delete it later).
  127.  
  128. In practice, I rarely use RXQUEUE, and it would only be for things
  129. like "dir /f c:\os2\* | rxqueue".  Even this idiom is no longer
  130. needed with the RexxUtil.dll utility functions.
  131.  
  132. Patrick Mueller - IBM Cary
  133.  
  134. ----- OS2REXX CFORUM appended at 15:58:31 on 92/05/06 GMT (by AACL0X7 at OS2CUST)
  135. Subject: EXECIO
  136. Ref: Append at 21:05:30 on 92/05/05 GMT (by PMUELLR at CARVM3)
  137.  
  138. I haven't played around much with the RexxUtil functions.  Sounds like I'm
  139. gonna like'm though.
  140.  
  141. On a different tangent.  Popular rumor has it that there are now, or will
  142. be REXX HLLAPI functions included either with Base or XS 1.0.  I can't seem
  143. to find any reference to this, though some people sware that they exist.
  144. (Granted, they might be tucked into the RexxUtil package--see above
  145. comment).
  146.  
  147. Anyone want to confirm or deny said rumor.  It would be REALLY NICE to have
  148. a simple way to write HLLAPI scripts.
  149.  
  150. Bruce
  151.  
  152. ----- OS2REXX CFORUM appended at 19:07:05 on 92/05/06 GMT (by PMUELLR at CARVM3)
  153. Subject: EXECIO
  154. Ref:     Append at 15:58:31 on 92/05/06 GMT (by AACL0X7 at OS2CUST)
  155.  
  156. From an extremely knowledgable source (can't vouch for it though,
  157. since I don't have extended services on my machine):
  158.  
  159. The module name is SAAHLAPI.DLL, and the doc is in RXHLLAPI.DOC in
  160. CMLIB if the APIs are installed..
  161.  
  162. Patrick Mueller - IBM Cary
  163.  
  164. ----- OS2REXX CFORUM appended at 21:21:20 on 92/05/06 GMT (by CNADLER at WMAVM1)
  165. Subject: EXECIO
  166. Ref:     Append at 15:58:31 on 92/05/06 GMT (by AACL0X7 at OS2CUST)
  167.  
  168. The references are in the Extended Services publications. The DLL file
  169. that is necessary for HLLAPI support is installed when you install the
  170. Communications Manager.
  171.  
  172. Cliff Nadler
  173. Federal Sector Services                              Rockville, MD
  174. IBM Federal Systems Company                PROFS: NADLER at WMAVM7
  175.  
  176. ----- OS2REXX CFORUM appended at 21:49:27 on 92/05/06 GMT (by XXMINC08 at TORVMCOP)
  177. Subject: REXX HLLAPI
  178. Ref:     Append at 15:58:31 on 92/05/06 GMT (by AACL0X7 at OS2CUST)
  179. Hi,
  180.    I have a document sitting on my desk that was available online from
  181. one of the beta versions of ES (I don't know for sure, but suspect it
  182. was the 6.177 code).  It is called the REXX EHLLAPI PROGRAMMERS
  183. REFERENCE AND USERS GUIDE!
  184.    The hllapi interface is supposed to be installed by extended services
  185. whenever you have selected 3270 or 5250 emulation features.  The
  186. interface is contained in the file \CMLIB\DLL\SAAHLAPI.DLL.
  187.    To make hllapi functions available to rexx, do the following.
  188. if rxfuncquery('hllapi') then call rxfuncadd 'hllapi','saahlapi',
  189.                                                     'hllapisrv'
  190. all functions are then available thru a single call as follows
  191.           HLLAPI( function-string , parameters )
  192. I have verified that this DLL still exists in the 6.304e code, but I
  193. can't seem to find the documentation online anywhere.
  194. Hope this helps.
  195.  
  196. Bill Nelson
  197. Manulife Financial
  198.  
  199. ----- OS2REXX CFORUM appended at 15:20:04 on 92/05/07 GMT (by AACL0X7 at OS2CUST)
  200. Subject: REXX HLLAPI
  201. Ref: Append at 21:49:27 on 92/05/06 GMT (by XXMINC08 at TORVMCOP)
  202.  
  203. Thanks--the DLL does indeed exist on my machine.  No wonder I cound't intuit
  204. the connect however.  I hope the documentation will be available when XS 1.0
  205. is release again (we've been told that shipments have been stopped)--all I've
  206. got is some beta--and can't even remember what version it is.  Well, I'm
  207. gonna go play with it...
  208.  
  209. Bruce
  210.  
  211. ----- OS2REXX CFORUM appended at 13:58:10 on 92/05/08 GMT (by PASPUNG at CARVM3)
  212. ..... OS2REXX CFORUM modified at 18:55:42 on 92/05/08 GMT (by PASPUNG at CARVM3)
  213. Subject: Load/call rexx function from a DLL
  214.  
  215. I'm trying to create a DLL using C Set/2 which provides an external function
  216. for Rexx.  (For those of you who have it, I'm trying to work through the
  217. article "Extending the Functions of OS/2 Rexx" in the January, 1992 issue
  218. of "Personal Systems Technical Solutions".  However, I'm using 2.0, C Set/2,
  219. and LINK386.)  I am a little wet behind the ears regarding DLLs, so please
  220. excuse any naivity.
  221.  
  222. When I call RxFuncAdd, the functions don't seem to get added, and a call
  223. to any of them produces "REX0043: ... Routine not found".  The only
  224. thing that seems in error is a message produced by the linker.  I'm linking
  225. w/ libs OS2386, and DDE4SBS.  When the linker completes, I get this warning:
  226.    LINK386 : error L4038: program has no starting address
  227.  
  228. Is this significant, or even the cause of my problem?  I've placed a call
  229. to the author of the article, but he's in class until Monday.  Any insight
  230. would be greatly appreciated!
  231.  
  232. |Answering my own append...
  233. |
  234. |Found a great sample in the 2.0 Toolkit that showed me exactly how to do this.
  235. |Turns out I had several things wrong, and the sample pointed me in the right
  236. |direction.  It's the Rexx sample rxmacdll.  Look at macro.* in the \toolkt20\
  237. |rexx\samples\rxmacdll directory for clues.
  238.  
  239. Peter A. Spung, IBM Application Platform Products MDQ Chair, Cary, NC (TEAMOS2)
  240.  
  241. ----- OS2REXX CFORUM appended at 20:36:14 on 92/05/08 GMT (by PRICESG at GDLVM7)
  242. Subject: Load/call rexx function from a DLL
  243. Ref:     Append at 13:58:10 on 92/05/08 GMT (by PASPUNG at CARVM3)
  244.  
  245. I suspect your problem not with RxFuncAdd, but that you had the error
  246. linking the DLL.  When a DLL is bad, RxFuncAdd will work OK but the
  247. actual call will produce REXX error 43, Function not Found.
  248.  
  249. To fix the link error, try styling your MAK and DEF files after the
  250. ones for the REXXUTIL sample in the 2.0 toolkit.  This sample is an
  251. external function package written as a C DLL.  It is in
  252. \toolkt20\rexx\samples\rexxutil.
  253.  
  254. Steve Price     IBM SAA REXX Development
  255.  
  256. ----- OS2REXX CFORUM appended at 15:23:07 on 92/05/12 GMT (by WZ00533 at OS2CUST)
  257. Subject: Object Oriented Rexx
  258.  
  259. At the most recent SHARE (March in Aneheim CA), I attended an IBM demonstration
  260. of an object oriented Rexx.  It looked great.  The presentor was carefull to
  261. state the product was internal only and may never be released.  Having said
  262. that, are you aware of any plans to release it?  It sure would be a
  263. great prototyping tool, as well as a great enhancement to Rexx's capabilities
  264. as a general purpose OS/2 'macro' language.
  265.  
  266. Dave
  267.  
  268. ----- OS2REXX CFORUM appended at 22:06:36 on 92/05/12 GMT (by IL22661 at OS2CUST)
  269. Subject: OS/2 Workplace Shell support
  270.  
  271. I am interested in the OS/2 Workplace Shell support of 2/REXX.  I have coded
  272. some REXX programs for our users and I would like to be able to pop up a
  273. window to prompt the user for some info.  Is it possible to do this from
  274. REXX?
  275.  
  276. Right now I have the command executing in a OS/2 full screen window.  I would
  277. like to run from an icon and prompt for the information like LAN Requester
  278. does when it prompts for the logon id and password.
  279.  
  280. A year or so ago, I attended a presentation by a developer from Boca Raton
  281. in which he presented his REXX-to-PM API.  He said that it was experimental
  282. and he did not know if it would be added to 2/REXX.  Is that capability now
  283. in 2/REXX under OS/2 2.0?
  284.  
  285. If this capability is available, is there documentation available (with
  286. examples, I hope) that show how this work?
  287.  
  288. ----- OS2REXX CFORUM appended at 16:45:23 on 92/05/13 GMT (by 64911426 at TOROHON1)
  289. Subject: REXX HLLAPI
  290. Ref:     Append at 21:49:27 on 92/05/06 GMT (by XXMINC08 at TORVMCOP)
  291.  
  292. I can't find any reference to RXHLLAPI.DOC in the ES GA code even though
  293. 3270 emulation was selected during ES install. Module SAAHLAPI.DLL
  294. is present. Where/how can I access the DOC file??
  295. Wally Stubgen  PH. (519) 749-7316
  296.  
  297. ----- OS2REXX CFORUM appended at 19:17:37 on 92/05/13 GMT (by XXMINC08 at TORVMCOP)
  298. Subject: REXX HLLAPI
  299. Ref:     Append at 16:45:23 on 92/05/13 GMT (by 64911426 at TOROHON1)
  300.  
  301. Wally,
  302.    My copy of the document says that 'this document is installed
  303. when the API Data Structures selection of the Communications Manager
  304. Additional Features is installed.  This file is installed in the
  305. c:\cmlib directory.'.
  306.    So ... you should be able to get it by running ESINST, selecting
  307. Communication Manager Install, and select API Data Structures.
  308. Good luck ...
  309.  
  310. Bill Nelson
  311. Manulife Financial
  312.  
  313. ----- OS2REXX CFORUM appended at 20:58:19 on 92/05/13 GMT (by CNADLER at WMAVM1)
  314. Subject: OS/2 Workplace Shell support
  315. Ref:     Append at 22:06:36 on 92/05/12 GMT (by IL22661 at OS2CUST)
  316.  
  317. Check out the REXXUTIL functions (they are in the REXX Reference and in
  318. the online reference). They will allow you to put up a single message
  319. box, plus update the INI files and other dangerous things !-)
  320.  
  321. Cliff Nadler
  322. Federal Sector Services                              Rockville, MD
  323. IBM Federal Systems Company                PROFS: NADLER at WMAVM7
  324.  
  325. ----- OS2REXX CFORUM appended at 13:54:14 on 92/05/14 GMT (by XXTCAN06 at TORVMCOP)
  326. Subject: OS/2 Workplace Shell support
  327. Ref:     Append at 20:58:19 on 92/05/13 GMT (by CNADLER at WMAVM1)
  328.  
  329. Then does anybody know why the verbatim example from the REXX reference
  330. doesn't work?  To wit:
  331.  
  332. ìD:\odds&ends┘msgbox
  333.      3 *-*   Call RxFuncAdd 'SysLoadFuncs', 'RexxUtil', 'SysLoadFuncs';
  334.        >L>     "SysLoadFuncs"
  335.        >L>     "RexxUtil"
  336.        >L>     "SysLoadFuncs"
  337.        >>>     "1"
  338.      4 *-*   Call SysLoadFuncs;
  339.        >>>     ""
  340.      6 *-*   If RxMessageBox('Shall we continue',, 'YesNo', 'Query') = 7;
  341.        >L>     "Shall we continue"
  342.        >L>     "YesNo"
  343.        >L>     "Query"
  344.      6 +++   If RxMessageBox('Shall we continue',, 'YesNo', 'Query') = 7;
  345. REX0040: Error 40 running D:\odds&ends\MsgBox.cmd, line 6: Incorrect call
  346. to routine
  347.  
  348.                                                 Pierre Legault
  349.                                                 Transport Canada
  350.                                                 1-613-993-7149
  351.  
  352. ----- OS2REXX CFORUM appended at 14:33:58 on 92/05/14 GMT (by MCGUIRE at GDLVM7)
  353. Subject: OS/2 Workplace Shell support
  354. Ref:     Append at 13:54:14 on 92/05/14 GMT (by XXTCAN06 at TORVMCOP)
  355.  
  356. RxMessageBox can only be used in a PM session (i.e., run from PMREXX or from
  357. a macro called from a PM session).
  358.  
  359. Rick McGuire - SAA Rexx Development, Endicott
  360.  
  361. ----- OS2REXX CFORUM appended at 14:42:07 on 92/05/14 GMT (by VERSTEEG at UITVM1)
  362. Subject: OS/2 Workplace Shell support
  363. Ref:     Append at 13:54:14 on 92/05/14 GMT (by XXTCAN06 at TORVMCOP)
  364.  
  365. According to my manual the verbatim is:
  366.  
  367.        If RxMessageBox('Shall we continue',, 'YesNo', 'Query') = 7
  368.        Then Exit
  369.  
  370. Note that the semicolon is optional in REXX.
  371. Normally it is only used if you have more than statement on a line
  372. like:
  373.  
  374.       a=1; b=2; c=3;
  375.  
  376. Anton Versteeg - ESAT PWS CoC Uithoorn, NL
  377.  
  378. ----- OS2REXX CFORUM appended at 15:02:08 on 92/05/14 GMT (by XXTCAN06 at TORVMCOP)
  379. Subject: OS/2 Workplace Shell support
  380. Ref:     Append at 14:42:07 on 92/05/14 GMT (by VERSTEEG at UITVM1)
  381.  
  382.   The output that I pasted in my append came from a run of the exec that
  383. had 'trace i' at its beginning.  It take it, then, that the trace output
  384. was from the tokenized representation of the exec, rather than the actual
  385. source file; that would be why a ';' appeared at the end of each line.
  386.   The actual source file was:
  387. -------------------------------------------------------------------------
  388. /* rexx */
  389. trace i
  390. call RxFuncAdd 'SysLoadFuncs', 'RexxUtil', 'SysLoadFuncs'
  391. call SysLoadFuncs
  392.                                         /* Give option to quit        */
  393.    if RxMessageBox("Shall we continue",, "YesNo", "Query") = 7
  394.      Then Exit                          /* quit option given, exit    */
  395. -------------------------------------------------------------------------
  396.   But my query was answered when it was pointed out to me that the exec
  397. had to be called by a PM session (eg PMREXX).
  398.  
  399.                                                 Pierre Legault
  400.                                                 Transport Canada
  401.                                                 1-613-993-7149
  402.  
  403. ----- OS2REXX CFORUM appended at 17:02:58 on 92/05/14 GMT (by IL22661 at OS2CUST)
  404. Subject: OS/2 Workplace Shell support
  405.  
  406. Thank you for pointing me to the RxMessageBox fuction and its usage and the
  407. additional information on PMREXX.
  408.  
  409. I still do not see a way I can collect data from the user using this function.
  410. Maybe I can have them pick from choices, but I cannot collect character data.
  411. Am I right or maybe I cannot see it with my overworked mind?
  412.  
  413. What I need is an RxQuery function to drive a window that asks for information
  414. like:
  415.          Please enter the Host Computer Name and Application Name desired:
  416.                      Hostname    | ______________|
  417.                      Application |_______________|
  418.             OK                                                Cancel
  419.          |_______|                                          |_________|
  420.  
  421. Can this be done?
  422.  
  423. Emilio A. Icaza, Ph.D.
  424. Louisiana State University
  425. (504) 388-3750
  426.  
  427. ----- OS2REXX CFORUM appended at 17:20:17 on 92/05/14 GMT (by WZ00533 at OS2CUST)
  428. Subject: OS/2 Workplace Shell support
  429. Ref: Append at 15:02:08 on 92/05/14 GMT (by XXTCAN06 at TORVMCOP)
  430.  
  431. If I may jump in and offer my two cents....
  432. If in fact I can display a message box in rexx ONLY from a PM session
  433. ala PMREXX, then what good is it?????  Or stated another way.
  434.  
  435. Other than PMREXX, how can I run a rexx exec in a PM session?  Yes I know
  436. I can call rexx from C (does that make sense!).
  437.  
  438. If I have asked a stupied question, your free to say so, you wouldn't be the
  439. first.  I happen to like rexx a lot, and would like to see it enhanced to
  440. include the capability to 'do it all', i.e PM stuff, object oriented stuff
  441. (refer to my earlier note on OOREXX).  After all we can now do HLLAPI, CPI-C,
  442. why should we be satisfied with text mode I/O?
  443.  
  444. Thanks,
  445. Dave
  446.  
  447. ----- OS2REXX CFORUM appended at 21:07:23 on 92/05/14 GMT (by XXTCAN06 at TORVMCOP)
  448. Subject: OS/2 Workplace Shell support
  449. Ref:     Append at 17:02:58 on 92/05/14 GMT (by IL22661 at OS2CUST)
  450.  
  451.   You might want to investigate the 'Dialog Manager' for OS/2.  It is an
  452. OS/2 implementation of ISPF.  But, from what I read a few months back,
  453. IBM is planning to drop it (if it hasn't already).
  454.   Can anybody else offer any information on that subject?
  455.  
  456.                                                 Pierre Legault
  457.                                                 Transport Canada
  458.                                                 1-613-993-7149
  459.  
  460. ----- OS2REXX CFORUM appended at 01:48:53 on 92/05/15 GMT (by PMUELLR at CARVM3)
  461. Subject: OS/2 Workplace Shell support
  462. Ref:     Append at 17:20:17 on 92/05/14 GMT (by WZ00533 at OS2CUST)
  463.  
  464. There are PM applications that use rexx as a macro language (such as
  465. the text editor in WorkStation Platform/2 1.2).  These applications
  466. can take advantage of the rexx functions in RexxUtil.dll such as the
  467. message box function.
  468.  
  469. Patrick Mueller - IBM Cary
  470.  
  471. ----- OS2REXX CFORUM appended at 11:09:53 on 92/05/15 GMT (by MCGUIRE at GDLVM7)
  472. Subject: OS/2 Workplace Shell support
  473. Ref:     Append at 17:20:17 on 92/05/14 GMT (by WZ00533 at OS2CUST)
  474.  
  475. Well, you can pop up a message box from EPM editor macros as a start.  Once
  476. Borland ObjectVision is available, you'll be able to use it from ObjectVision
  477. Rexx programs.  Ditto for when the SourceLink editor is available with Rexx
  478. support.  There are many more ways to run Rexx programs than just command
  479. line batch programs.  RxMessageBox was designed for these "other ways".
  480.  
  481. Rick McGuire - SAA Rexx Development, Endicott
  482.  
  483. ----- OS2REXX CFORUM appended at 11:12:40 on 92/05/15 GMT (by MCGUIRE at GDLVM7)
  484. Subject: OS/2 Workplace Shell support
  485. Ref:     Append at 17:02:58 on 92/05/14 GMT (by IL22661 at OS2CUST)
  486.  
  487. There isn't yet a native function that allows that sort of access.  You might
  488. want to investigate Borland ObjectVision when it becomes available in June.
  489. Its Rexx support makes it a very attractive way of doing PM based Rexx
  490. programs.
  491.  
  492. Rick McGuire - SAA Rexx Development, Endicott
  493.  
  494. ----- OS2REXX CFORUM appended at 11:33:06 on 92/05/15 GMT (by WZ00533 at OS2CUST)
  495. Subject: OS/2 Workplace Shell support
  496. Ref: Append at 11:09:53 on 92/05/15 GMT (by MCGUIRE at GDLVM7)
  497.  
  498. Hi Rick,
  499.  
  500. Thanks for the reply.  I am looking foward to Objectvision.  I guess I was
  501. looking for rexx to be more than 'just' a macro language.
  502.  
  503. Dave
  504.  
  505. ----- OS2REXX CFORUM appended at 12:33:26 on 92/05/15 GMT (by VERSTEEG at UITVM1)
  506. Subject: OS/2 Workplace Shell support
  507. Ref:     Append at 11:33:06 on 92/05/15 GMT (by WZ00533 at OS2CUST)
  508.  
  509. Also nice with ObjectVision is the support for DBMS's
  510. like dBase, Paradox and Database Manager.
  511. (via the SQL link option)
  512.  
  513. I saw a short demo of a beta version last week.
  514. What I specially liked was the ability to do database updates
  515. from a table window (multiple rows and columns).
  516. The clipboard can be used to copy/paste data across fields.
  517. Another thing I like is that you can distribute your applications free.
  518. No runtime license.
  519.  
  520. Anton Versteeg - ESAT PWS CoC Uithoorn, NL
  521.  
  522. ----- OS2REXX CFORUM appended at 11:24:00 on 92/05/18 GMT (by WZ00533 at OS2CUST)
  523. Subject: Named Pipes
  524.  
  525. I noticed a Rexxutil function call SysWaitNamedPipe (or something like that).
  526.  
  527. I did not see any other references to named pipes!  Can someone illuminate me
  528. as to the extent of named pipe support within rexx?  I tried the Steams
  529. function to no avail.
  530.  
  531. Related, in the 2.0 Development Toolkit, I found the source for previouslly
  532. mentioned function, along with 'references' to other named pipes functions, but
  533. NO source.
  534.  
  535. Any ideas?
  536.  
  537. ----- OS2REXX CFORUM appended at 14:37:37 on 92/05/18 GMT (by PRICESG at GDLVM7)
  538. Subject: Named Pipes
  539. Ref:     Append at 11:24:00 on 92/05/18 GMT (by WZ00533 at OS2CUST)
  540.  
  541. SysWaitNamePipe is the only REXX function just for named pipes.  You
  542. can't create a named pipe in the REXX program (we were thinking of
  543. putting that function in, but didn't work out a neat way to do it).
  544. You can read and write named pipes (that are created by other
  545. programs) using the normal REXX I/O functions.
  546.  
  547. Steve Price    IBM SAA REXX Development
  548.  
  549. ----- OS2REXX CFORUM appended at 16:44:52 on 92/05/18 GMT (by WZ00533 at OS2CUST)
  550. Subject: Named Pipes
  551. Ref: Append at 14:37:37 on 92/05/18 GMT (by PRICESG at GDLVM7)
  552.  
  553. Steve,
  554. Thanks for the reply.
  555. If I were to try my hand at creating my own named pipe function (using the code
  556. from the toolkit for SysWaitNamePipe as an example) are there any issues
  557. I should be aware of?
  558.  
  559. ----- OS2REXX CFORUM appended at 16:44:33 on 92/05/19 GMT (by WZ00533 at OS2CUST)
  560. Subject: SysCreateObject
  561.  
  562. A user somehow 'lost' their Minimized Window Viewer.  First I tried to find
  563. it using the 'Find' menu option without success.  I then tried to use the
  564. SysCreateObject RexxUtil function on my PC to create one.  If I used the
  565. an OBJECTID of WP_VIEWER the function failed (correctly, I suppose, because
  566. I already had one).  So I used WP_VIEWER2 as an OBJECTID and I got my second
  567. viewer...great.  Now before I do this for my user.... How do I delete this
  568. object??????  Dragging it to the shredder fails, (I get the circle with the
  569. line through it).
  570.  
  571. A while back I had created a Network Folder using the same technique.  I
  572. was also unable to delete it!
  573.  
  574. A general question is:
  575. How do I delete objects created with RexxUtil's SysCreateObject.
  576.  
  577. Thanks,
  578. Dave
  579.  
  580. ps. My inability to delete the second viewer has made me wonder how my user
  581. 'lost' hers!!!!, she claims she may have 'deleted it.
  582.  
  583. ----- OS2REXX CFORUM appended at 16:47:19 on 92/05/19 GMT (by WZ00533 at OS2CUST)
  584. ..... OS2REXX CFORUM modified at 17:36:50 on 92/05/19 GMT (by WZ00533 at OS2CUST)
  585. Subject: SysCreateObject
  586.  
  587. A user somehow 'lost' their Minimized Window Viewer.  First I tried to find
  588. it using the 'Find' menu option without success.  I then tried to use the
  589. SysCreateObject RexxUtil function on my PC to create one.  If I used the
  590. an OBJECTID of WP_VIEWER the function failed (correctly, I suppose, because
  591. I already had one).  So I used WP_VIEWER2 as an OBJECTID and I got my second
  592. viewer...great.  Now before I do this for my user.... How do I delete this
  593. object??????  Dragging it to the shredder fails, (I get the circle with the
  594. line through it).
  595.  
  596. A while back I had created a Network Folder using the same technique.  I
  597. was also unable to delete it!
  598.  
  599. A general question is:
  600. How do I delete objects created with RexxUtil's SysCreateObject which can
  601. no be deleted using the shredder?
  602. Thanks,
  603. Dave
  604.  
  605. ps. My inability to delete the second viewer has made me wonder how my user
  606. 'lost' hers!!!!, she claims she may have 'deleted it.
  607.  
  608. pss.  I figured out a way to delete said object.  I removed the directory!
  609. then I could delete it!  Is this the official way to delete such objects?
  610.  
  611. ----- OS2REXX CFORUM appended at 12:13:29 on 92/05/21 GMT (by TEMP19GC at CLTVM1)
  612. Subject: Loading REXX on OS/2 2.0
  613.  
  614. I am writing a REXX program to install Extended Services and LAN
  615. requester and I want to load REXX via a LAN onto a machine that does not
  616. have REXX installed.  I have loaded rexx.dll, rexxapi.dll, rexxinit.dll,
  617. and rexxutil.dll but the REXX program will not use the REXX utilities.
  618. It does however use the basic REXX statements like "say".
  619. Any ideas.
  620.  
  621. Thanks,
  622.  
  623. Aubrey Hawes
  624.  
  625. ----- OS2REXX CFORUM appended at 12:54:27 on 92/05/21 GMT (by PRICESG at GDLVM7)
  626. ..... OS2REXX CFORUM modified at 17:46:59 on 92/05/22 GMT (by PRICESG at GDLVM7)
  627. Subject: Loading REXX on OS/2 2.0
  628. Ref:     Append at 12:13:29 on 92/05/21 GMT (by TEMP19GC at CLTVM1)
  629.  
  630. | modified to correct name of DLL listing in LoadOneTime
  631.  
  632. Short answer:  use selective install to add REXX to a system which
  633. is missing it.  There's more involved than adding those four files.
  634.  
  635. Long answer:
  636.  
  637. On a system with REXX installed and working, REXXINIT.DLL is loaded
  638. during PM initialization.  REXXINIT.DLL starts a thread that controls
  639. REXX's global data, such as the list of external functions.  It sounds
  640. like your problem is that REXXINIT is not getting loaded.
  641.  
  642. OS/2 keeps a list of the DLLs that should be loaded in OS2.INI.  If
  643. you happen to have a tool for browsing and changing INI files, you can
  644. look for app name "SYS_DLLS", key name "LoadOneTime".  This should
  645. contain a small list of names including REXXINIT.  This list is read
  646. by PM while the desktop is initialized and controls which DLLs get
  647. loaded (beyond those needed to run PM).
  648.  
  649. Finally, there are other REXX files besides the DLLs you listed.
  650. Selective install will get them all.
  651.  
  652. Steve Price      IBM SAA REXX Development
  653.  
  654. ----- OS2REXX CFORUM appended at 13:16:22 on 92/05/21 GMT (by TEMP19GC at CLTVM1)
  655. Subject: Loading REXX on OS/2 2.0
  656. Ref:     Append at 12:54:27 on 92/05/21 GMT (by PRICESG at GDLVM7)
  657.  
  658. What are the other REXX files that you get from a selective install?
  659.  
  660. Thanks,
  661.  
  662. Aubrey Hawes
  663.  
  664. ----- OS2REXX CFORUM appended at 14:02:02 on 92/05/21 GMT (by PRICESG at GDLVM7)
  665. Subject: Loading REXX on OS/2 2.0
  666. Ref:     Append at 13:16:22 on 92/05/21 GMT (by TEMP19GC at CLTVM1)
  667.  
  668. I should've known you'd ask.   RXSUBCOM.EXE, RXQUEUE.EXE, REX.MSG,
  669. REXH.MSG.  The EXEs go in \OS2; the MSGs go in \OS2\SYSTEM.
  670.  
  671. Note that this information could change in the future.
  672.  
  673. Steve Price    IBM SAA REXX Development
  674.  
  675. ----- OS2REXX CFORUM appended at 17:44:11 on 92/05/21 GMT (by IL22868 at OS2CUST)
  676. Subject: SysCreateObject
  677. Ref: Append at 16:47:19 on 92/05/19 GMT (by WZ00533 at OS2CUST)
  678.  
  679. I have HEARD that this works, but have not tried it myself: Try
  680. putting the object you wish to delete into a Folder (you will
  681. probably want to create a new folder for this purpose) and then drag
  682. the folder containing the object to the shredder.  Apparently it is
  683. only a PAPER shredder :-).
  684.  
  685. Ken Singer
  686.  
  687. ----- OS2REXX CFORUM appended at 13:21:53 on 92/05/22 GMT (by HARGRAVE at BCRVMPC1)
  688. Subject: Loading REXX on OS/2 2.0
  689. Ref:     Append at 12:54:27 on 92/05/21 GMT (by PRICESG at GDLVM7)
  690.  
  691. For clarity and completeness, the SYS_DLLS LoadOneTime value contains
  692. REXXINIT not REXXUTIL.
  693.  
  694. BJ Hargrave
  695.  
  696. ----- OS2REXX CFORUM appended at 19:52:57 on 92/05/22 GMT (by CHVY006 at OS2CUST)
  697. Subject: Compressed Rexx Proc
  698.  
  699. I've observer that the Rexx to SQL interface given with DBM is
  700. compressed and will like to compress some of my bulk rexx projects.
  701. How do you do this? and How do you undo it?
  702.  
  703. Carlton
  704.  
  705. ----- OS2REXX CFORUM appended at 14:46:15 on 92/05/25 GMT (by VERSTEEG at UITVM1)
  706. Subject: Compressed Rexx Proc
  707. Ref:     Append at 19:52:57 on 92/05/22 GMT (by CHVY006 at OS2CUST)
  708.  
  709. It is probably done with a private (REXX) program.
  710. You basically replace CR/LF with a semicolon.
  711. Theoretically you can put a complete program on one line.
  712. This is often done with REXX programs on the VM platform.
  713.  
  714. Anton Versteeg - ESAT PWS CoC Uithoorn, NL       *** GO OS/2 2.0 ***
  715.  
  716. ----- OS2REXX CFORUM appended at 13:21:17 on 92/05/26 GMT (by MCGUIRE at GDLVM7)
  717. Subject: Named Pipes
  718. Ref:     Append at 16:44:52 on 92/05/18 GMT (by WZ00533 at OS2CUST)
  719.  
  720. The problems we ran into with named pipe functions revolve around how the
  721. server side creates and connects to the pipes.  Because the server side has
  722. to connect to the pipe rather than open the pipe, you cannot use linein and
  723. lineout to access the pipe.  To write this sort of support, you need functions
  724. for connect, disconnect, create, read and write.
  725.  
  726. Rick McGuire - SAA Rexx Development, Endicott
  727.  
  728. ----- OS2REXX CFORUM appended at 17:15:03 on 92/05/27 GMT (by IL06795 at OS2CUST)
  729. Subject: Rexx Source Code
  730.  
  731. Is there some way to protect the rexx source code from user changes?
  732.  
  733. Somebody mentioned creating an intermeidiate (sp) file, kind of like a
  734. bound file and executing that.  I've looked thru the sea of inf files
  735. and can't find anything addressing this.  Suggestions?
  736.  
  737. Ralph Porter - Chicago Mercantile Exchange
  738.  
  739. ----- OS2REXX CFORUM appended at 20:27:54 on 92/05/27 GMT (by CONT06 at LEXVMK)
  740. Subject: Rexx Source Code
  741. Ref:     Append at 17:15:03 on 92/05/27 GMT (by IL06795 at OS2CUST)
  742.  
  743. Have a look at Macrospace Interface.  You can save and load tokenized
  744. REXX code.  You can ship tokenized code only.
  745.  
  746. Leshek J. Fiedorowicz - Team OS/2            Lexington  1992/05/27  16:24
  747.                                                                JRFB70A@*P
  748.  
  749. ----- OS2REXX CFORUM appended at 20:41:29 on 92/05/27 GMT (by MCGUIRE at GDLVM7)
  750. Subject: Rexx Source Code
  751. Ref:     Append at 17:15:03 on 92/05/27 GMT (by IL06795 at OS2CUST)
  752.  
  753. You can hide the source code by loading the program into the macro space and
  754. then saving the macro space.  There are some sample programs in the OS/2
  755. 2.0 Toolkit that will allow you to do this easily.  However, there is a VERY
  756. big caveat with this:  The program image saved in the macro space is HIGHLY
  757. version specific.  A 1.3 macro space will not run with a 2.0 interpreter, and
  758. vice versa.  In addition, the saved image may not run with interpreters at
  759. different service levels.  If you have a fairly homogeneous environment, then
  760. this will work.  If you have a variety of system levels, this will not work.
  761.  
  762. Rick McGuire - SAA Rexx Development, Endicott
  763.  
  764. ----- OS2REXX CFORUM appended at 20:49:57 on 92/05/27 GMT (by TRAUTMAN at PKEDVM8)
  765. Subject: Rexx Source Code
  766. Ref:     Append at 17:15:03 on 92/05/27 GMT (by IL06795 at OS2CUST)
  767.  
  768. A solution for a LAN based environment would be to place the Rexx
  769. code on a Read Only disk on the LAN.  You might want to look
  770. at some of the functions for dealing with rexx macrospace.
  771. you might be able to insert the rexx code into the macrospace and
  772. make use of it from there.  Documentation on the rexx macrospace is
  773. near the end of the Rexx reference from the OS/2 2.0 toolkit.
  774.  
  775. Bill Trautman
  776.  
  777. ----- OS2REXX CFORUM appended at 15:06:54 on 92/05/28 GMT (by TEMP19GC at CLTVM1)
  778. Subject: Calling a REXX Program from STARTUP.CMD
  779.  
  780. I am calling a REXX program form OS/2 2.0's STARTUP.CMD.  The program
  781. runs fine except I am unable to create files using LINEOUT.  I get a
  782. return code of 1.  If I run the program from the command line it works
  783. fine and I get a return code of 0.  My STARTUP.CMD is as follows:
  784.   @Echo Off
  785.   start c:\esmenu c:\
  786.   exit
  787.  
  788. Any ideas
  789.  
  790. Thanks,
  791.  
  792. Aubrey Hawes
  793.  
  794. ----- OS2REXX CFORUM appended at 18:12:57 on 92/05/28 GMT (by TMARTIN at NHBVM4)
  795. Subject: Calling a REXX Program from STARTUP.CMD
  796. Ref:     Append at 15:06:54 on 92/05/28 GMT (by TEMP19GC at CLTVM1)
  797.  
  798. I just tried to recreate the problem, and couldn't.
  799. I can't see anything wrong with what you've done.
  800. Could you show us the listing of esmenu?  If you do, I'll
  801. try that on my system and see if I can get the problem.
  802.  
  803. Best wishes.
  804.  
  805.                     Tim Martin  (TMARTIN @ NHBVM4)  1992/05/28 19:10 BST
  806.  
  807. ----- OS2REXX CFORUM appended at 19:44:54 on 92/05/28 GMT (by TEMP19GC at CLTVM1)
  808. ..... OS2REXX CFORUM modified at 20:08:05 on 92/05/28 GMT (by TEMP19GC at CLTVM1)
  809. Subject: Calling a REXX Program from STARTUP.CMD
  810. Ref:     Append at 18:12:57 on 92/05/28 GMT (by TMARTIN at NHBVM4)
  811.  
  812. code sent to TMARTIN at NHBVM4
  813.  
  814. Aubrey Hawes
  815.  
  816. ----- OS2REXX CFORUM appended at 15:22:41 on 92/05/29 GMT (by TMARTIN at NHBVM4)
  817. Subject: Calling a REXX Program from STARTUP.CMD
  818. Ref:     Append at 19:44:54 on 92/05/28 GMT (by TEMP19GC at CLTVM1)
  819.  
  820. Mmmm.  I'm having problems with this.  It may be that esmenu is deleting
  821. startup.cmd and config.sys, while the system is starting up.
  822.  
  823. However, while testing, I've somehow deleted all the files from the
  824. root of my c-drive.  I'll have to fix this before going any further.
  825. It could take some time ...
  826.  
  827.                     Tim Martin  (TMARTIN @ NHBVM4)  1992/05/29 16:20 BST
  828.  
  829. ----- OS2REXX CFORUM appended at 17:03:08 on 92/05/29 GMT (by TEMP19GC at CLTVM1)
  830. Subject: Calling a REXX Program from STARTUP.CMD
  831. Ref:     Append at 15:22:41 on 92/05/29 GMT (by TMARTIN at NHBVM4)
  832.  
  833. I don't think that is the problem because I have tried to call esmenu
  834. from another command file.
  835.  
  836. Thanks,
  837.  
  838. Aubrey Hawes
  839.  
  840. ----- OS2REXX CFORUM appended at 14:55:26 on 92/06/01 GMT (by SAMI3QU at OS2CUST)
  841. Subject: PMREXX and "REXX procedure has ended" message
  842.  
  843. Is there a way to supress the "The REXX procedure has ended" message when
  844. a PMREXX program terminates?  Thanks for any info.
  845.  
  846. Mark Thompson - Coal Services Corp.  St. Louis, MO
  847.  
  848. ----- OS2REXX CFORUM appended at 16:29:10 on 92/06/01 GMT (by CONT00 at LEXVMK)
  849. ..... OS2REXX CFORUM modified at 13:22:50 on 92/06/12 GMT (by CONT00 at LEXVMK)
  850. Subject: PMREXX and "REXX procedure has ended" message
  851. Ref:     Append at 14:55:26 on 92/06/01 GMT (by SAMI3QU at OS2CUST)
  852.  
  853. PMREXX's source is available in the Toolkit. If you don't have it, there
  854. would be no other way then zap the EXE...
  855. || The change to make is: comment lines 462 and 463 in PMREXX.C
  856.  
  857. Gregory Czaja, Lexington 8-545-3311  1992/06/01  12:25
  858.  
  859. ----- OS2REXX CFORUM appended at 17:16:44 on 92/06/02 GMT (by TEMP19GC at CLTVM1)
  860. Subject: Calling a REXX Program from STARTUP.CMD
  861. Ref:     Append at 17:03:08 on 92/05/29 GMT (by TEMP19GC at CLTVM1)
  862.  
  863. I have found something else out.  If I use the "START" command to call my
  864. program, my program will not be able to read, write, or create files.
  865. If I do not use the "START" command it works fine. Is the a way around
  866. this.  I have been playing with the "START" command options and I have
  867. not found anything. Any ideas...
  868.  
  869. Thanks,
  870.  
  871. Aubrey Hawes
  872.  
  873. ----- OS2REXX CFORUM appended at 20:06:44 on 92/06/02 GMT (by MCGUIRE at GDLVM7)
  874. Subject: Calling a REXX Program from STARTUP.CMD
  875. Ref:     Append at 17:16:44 on 92/06/02 GMT (by TEMP19GC at CLTVM1)
  876.  
  877. I'n unable to recreate this problem.  The simple tests I wrote were able to
  878. access files just file.  You might want to try placing TRACE I at the front of
  879. the program and invoking with:
  880.  
  881.   start myrexx 2>trace.out
  882.  
  883. to capture the trace output.  This may give some more information as to what
  884. is really happening.
  885.  
  886. Rick McGuire - SAA Rexx Development, Endicott
  887.  
  888. ----- OS2REXX CFORUM appended at 05:48:03 on 92/06/03 GMT (by OTISLIAO at TAIVM1)
  889. Subject: Using REXX to Control RS-232
  890.   Hi,
  891.       I am a new user of OS/2 REXX. I want to use REXX to detect the
  892.     signal from RS-232. But I can not find the commands to do this.
  893.       Is it possible to use REXX to do this ?
  894.  
  895. otis liao
  896.  
  897. ----- OS2REXX CFORUM appended at 12:51:15 on 92/06/03 GMT (by PERSHNG at YKTVMH)
  898. Subject: Access to LIBPATH?
  899.  
  900. Is there some way to get hold of a copy of the LIBPATH string from
  901. within a REXX procedure?
  902.  
  903. Lacking that, is there some way to determine the boot drive (e.g., 'C:')
  904. from within a REXX procedure, so that it can inhale the CONFIG.SYS file
  905. and get the LIBPATH by brute force?
  906.  
  907. John A. Pershing Jr.
  908.  
  909. ----- OS2REXX CFORUM appended at 13:00:51 on 92/06/03 GMT (by 86693596 at WARVM2)
  910. ..... OS2REXX CFORUM modified at 13:09:48 on 92/06/03 GMT (by 86693596 at WARVM2)
  911. Subject: Access to LIBPATH?
  912. Ref:     Append at 12:51:15 on 92/06/03 GMT (by PERSHNG at YKTVMH)
  913.  
  914. | Ahh, got it. Use the VALUE Function. Look it up in the Rexx Reference
  915. | under "Functions". The VALUE function allows you to both view and
  916. | change environment variables, amongst other things. If your goal is
  917. | to search for a file down the LIBPATH, the suggestion below may
  918. | still be useful.
  919.  
  920. I'm not sure about the string itself (still thinking...), but
  921. you can use the Rexx Utiltiy function SysSearchPath to search down
  922. the LIBPATH for a certain file. The function will return the full
  923. qualified filename of the file.
  924.  
  925. Andrew Agerbak, EAS Product Support, Brentford, UK
  926.  
  927. ----- OS2REXX CFORUM appended at 13:09:58 on 92/06/03 GMT (by SAMI3QU at OS2CUST)
  928. Subject: PMREXX and "REXX procedure has ended" message
  929. Ref: Append at 16:29:10 on 92/06/01 GMT (by CONT00 at LEXVMK)
  930.  
  931. Modify the source?  Ack!  I don't hate the message that badly!  I think I'll
  932. just leave this one alone.
  933.  
  934. Mark Thompson - Coal Services Corp.  St. Louis, MO
  935.  
  936. ----- OS2REXX CFORUM appended at 13:12:08 on 92/06/03 GMT (by PERSHNG at YKTVMH)
  937. ..... OS2REXX CFORUM modified at 13:20:06 on 92/06/03 GMT (by PERSHNG at YKTVMH)
  938. Subject: Access to LIBPATH?
  939. Ref:     Append at 13:00:51 on 92/06/03 GMT (by 86693596 at WARVM2)
  940.  
  941. Nope -- I want the string itself.
  942.  
  943. (I'm writing a utility that will inspect all of the directories in the
  944. path, and report any .DLL files in the front of the path that are
  945. "hiding" files found later on in the path.)
  946.  
  947. | The VALUE() function does not work.  LIBPATH does not appear to be
  948. | part of the OS/2 environment.  Anybody have any other ideas?
  949.  
  950. John A. Pershing Jr.
  951.  
  952. ----- OS2REXX CFORUM appended at 13:36:14 on 92/06/03 GMT (by 86693596 at WARVM2)
  953. Subject: Access to LIBPATH?
  954. Ref:     Append at 13:12:08 on 92/06/03 GMT (by PERSHNG at YKTVMH)
  955.  
  956. Hmmm, I just tried out my previous suggestion, and it only seems
  957. to work for PATH and DPATH, but not for LIBPATH:
  958.  
  959. /* Display Environment Variables */
  960. /* Andrew Agerbak 920603 */
  961. Say 'Path=' Value('PATH',,'OS2ENVIRONMENT')
  962. Say 'Dpath=' Value('DPATH',,'OS2ENVIRONMENT')
  963. Say 'LibPath=' Value('LIBPATH',,'OS2ENVIRONMENT')
  964.  
  965. OUTPUT:
  966.  
  967. Path= D:\OS2;D:\MUGLIB;D:\OS2\SYSTEM;D:\OS2\MDOS\WINOS2;C:\CMLIB;... (etc..)
  968. Dpath= D:\OS2;D:\MUGLIB\DLL;C:\CMLIB;C:\CMLIB\APPN;D:\OS2\SYSTEM;... (etc..)
  969. LibPath=
  970.  
  971. Is LibPath not an environment variable in the sense of the other two?
  972.  
  973. Andrew Agerbak, EAS Product Support, Brentford, UK
  974.  
  975. ----- OS2REXX CFORUM appended at 14:05:13 on 92/06/03 GMT (by PMUELLR at CARVM3)
  976. ..... OS2REXX CFORUM modified at 14:34:23 on 92/06/03 GMT (by PMUELLR at CARVM3)
  977. Subject: Access to LIBPATH?
  978. Ref:     Append at 13:36:14 on 92/06/03 GMT (by 86693596 at WARVM2)
  979.  
  980. LIBPATH never has been and probably never will be an environment
  981. variable.  You can't change it once you've booted.
  982.  
  983. You can determine the boot drive through some OS/2 api available in C -
  984. thus you could write an external rexx function to get it then read the
  985. correct config.sys - but what if I've made changes to my LIBPATH since
  986. I've booted???  I don't think there is a way to determine the actual
  987. libpath in use, in a completely reliable fashion.
  988.  
  989. ... removed stupid comment
  990.  
  991. Patrick Mueller - IBM Cary
  992.  
  993. ----- OS2REXX CFORUM appended at 17:06:34 on 92/06/03 GMT (by 61804212 at VIEVMA)
  994. Subject: Access to LIBPATH?
  995. Ref:     Append at 13:36:14 on 92/06/03 GMT (by 86693596 at WARVM2)
  996.  
  997. You can get the boot drive with the following code ("Ä" = backslash):
  998.  
  999. /***********************/
  1000. /* Find the boot drive */
  1001. /***********************/
  1002. Getbootdrive: Procedure
  1003. bootdrive = Value('PATH',,'OS2ENVIRONMENT')
  1004. Return Substr(bootdrive,Pos('ÄOS2ÄSYSTEM',bootdrive)-2,2)
  1005.  
  1006. Georg Haschek - OS/2 Project Office (06/03/92 19:00:15 CET)
  1007.  
  1008. ----- OS2REXX CFORUM appended at 18:04:01 on 92/06/03 GMT (by CONT06 at LEXVMK)
  1009. Subject: Using REXX to Control RS-232
  1010. Ref:     Append at 05:48:03 on 92/06/03 GMT (by OTISLIAO at TAIVM1)
  1011.  
  1012. Charin/Charout may be what you need (type HELP REXX CHARIN on os2 prompt).
  1013.  
  1014. Leshek J. Fiedorowicz - Team OS/2            Lexington  1992/06/03  14:01
  1015.                                                                JRFB70A@*P
  1016.  
  1017. ----- OS2REXX CFORUM appended at 22:10:28 on 92/06/03 GMT (by XXMINC08 at TORVMCOP)
  1018. Subject: Access to LIBPATH?
  1019. Ref:     Append at 14:05:13 on 92/06/03 GMT (by PMUELLR at CARVM3)
  1020.  
  1021. Patrick,
  1022.    In the first paragraph you mention that you can't change the LIBPATH
  1023. after you've booted, and in the second paragraph you are worried about
  1024. not being able to see any changes that have been made since boot time??
  1025.  
  1026.    It is my understanding that LIBPATH can never be changed after the
  1027. initial boot (probably because the OS/2 kernel reads it at boot time,
  1028. and hence would be useless to treat it like a normal environment var).
  1029.  
  1030.    Your solution, reading it from the CONFIG.SYS file, maybe doesn't
  1031. feel pretty ... but I think it should work ok if you can't find any
  1032. other way to get the value.  Good Luck.
  1033.  
  1034. Bill Nelson
  1035. Manulife Financial
  1036.  
  1037. ----- OS2REXX CFORUM appended at 03:30:54 on 92/06/04 GMT (by PMUELLR at CARVM3)
  1038. Subject: Access to LIBPATH?
  1039. Ref:     Append at 22:10:28 on 92/06/03 GMT (by XXMINC08 at TORVMCOP)
  1040.  
  1041. I meant that even if you figure out some way of getting to the boot
  1042. drive so you can read the config.sys, I might have changed the LIBPATH=
  1043. line in my config.sys since the system was booted.  Then the program
  1044. would be reading a line that wasn't the same as the LIBPATH= line the
  1045. system was booted with.  You probably don't really want to see this
  1046. changed line, but the value of the original line when the system was
  1047. booted.
  1048.  
  1049. I don't know if this would affect the guy who originally asked about
  1050. this - probably not much - but I bring it up since it was a pitfall
  1051. mentioned on one of our internal FORUMs a while back.  There doesn't
  1052. seem to be a general way to get the value of the LIBPATH the system
  1053. was booted with, with 100% certainty.
  1054.  
  1055. Patrick Mueller - IBM Cary
  1056.  
  1057. ----- OS2REXX CFORUM appended at 12:47:11 on 92/06/04 GMT (by PERSHNG at YKTVMH)
  1058. Subject: Access to LIBPATH?
  1059. Ref:     Append at 03:30:54 on 92/06/04 GMT (by PMUELLR at CARVM3)
  1060.  
  1061. The version of LIBPATH in the CONFIG.SYS file is sufficient for my
  1062. purposes -- thanks.
  1063.  
  1064. John A. Pershing Jr.
  1065.  
  1066. ----- OS2REXX CFORUM appended at 19:30:43 on 92/06/04 GMT (by UDSS013 at OS2CUST)
  1067. Subject: Access to LIBPATH? - Source Code!
  1068.  
  1069. Environment: procedure expose Dir.
  1070.    /**
  1071.    ***  This will list the contents of the environment variable.
  1072.    ***  It was designed to list those environment variables that are a
  1073.    ***  list of directories, separated by semicolons, such as a PATH or
  1074.    ***  DPATH variable.  Although it is not an environment variable, this
  1075.    ***  code will do the same for the LIBPATH by looking in the CONFIG.SYS
  1076.    **/
  1077.  
  1078.    arg EnvVariable .
  1079.  
  1080.    /* Take care of the special case for LIBPATH */
  1081.  
  1082.    if EnvVariable = 'LIBPATH' then
  1083.       do
  1084.       call SysFileSearch 'LIBPATH=', Dir.Boot'CONFIG.SYS', 'Libpath'
  1085.       if Libpath.0 \= 1 then
  1086.          do
  1087.          say "Warning. Possibly more than 1 LIBPATH in CONFIG.SYS"
  1088.          return
  1089.          end
  1090.       EnvValue = substr(Libpath.1, 9)  /* Remove the "LIBPATH=" */
  1091.       end /* if */
  1092.    else
  1093.       EnvValue = value(EnvVariable, , "OS2ENVIRONMENT")
  1094.  
  1095.       .
  1096.       .
  1097.       .
  1098.  
  1099. The code goes on to split the environment variable (or LIBPATH) with the
  1100. following code that fills the DirList stem.
  1101.  
  1102.   PathSplit: procedure expose DirList.
  1103.      /**
  1104.      ***  This will create a stem variable out of the semicolon-delimited
  1105.      ***  variable that is presumably retreived from a PATH or DPATH
  1106.      ***  environment.
  1107.      **/
  1108.  
  1109.      arg PathString .
  1110.  
  1111.      DirList = ''
  1112.      j = 1
  1113.      parse var PathString DirList.j ';' PathString
  1114.      do while DirList.j \= ''
  1115.         j = j + 1
  1116.         parse var PathString DirList.j ';' PathString
  1117.      end /* while */
  1118.      DirList.0 = j - 1
  1119.      return DirList.0
  1120.  
  1121. Also note the first routine used the RexxUtil, which requires the DLL to
  1122. be loaded.  That is done as follows:
  1123.  
  1124.            call RxFuncAdd 'SysLoadFuncs', 'RexxUtil', 'SysLoadFuncs'
  1125.            call SysLoadFuncs
  1126.  
  1127. Also note that the boot drive was set as part of the "Dir." stem variable in
  1128. the above code.  These are routines out of a larger (1700 line) REXX program.
  1129. Someone else posted a good way to determine the boot drive using the path.
  1130. I may have to incorporate that in the code.
  1131.  
  1132. Gary Murphy
  1133.  
  1134. ----- OS2REXX CFORUM appended at 21:05:46 on 92/06/04 GMT (by XXMINC08 at TORVMCOP)
  1135. Subject: Access to LIBPATH?
  1136. Ref:     Append at 03:30:54 on 92/06/04 GMT (by PMUELLR at CARVM3)
  1137.  
  1138. Patrick,
  1139.    Now I understand what you were saying ...
  1140.  
  1141. Bill Nelson
  1142. Manulife Financial
  1143.  
  1144. ----- OS2REXX CFORUM appended at 22:23:45 on 92/06/10 GMT (by USBC076 at OS2CUST)
  1145. Subject: Refreshing Icon Display
  1146.  
  1147. Is there a way to get REXX to refresh the workplace shell icon display? If I
  1148. issue a SysSetIcon for a folder I have placed on my desktop, I get a RC=1, but
  1149. the actual new icon does not display until I open the settings for the object.
  1150. I would like to run a REXX exec when I log onto the LAN that changes an icon
  1151. on my desktop (like, from a red light to a green one?) when I log on, and so
  1152. on, but am apparently missing some sort of refresh capability?
  1153.  
  1154. Robert D. Young, United States National Bank
  1155.  
  1156. ----- OS2REXX CFORUM appended at 09:38:50 on 92/06/11 GMT (by DAVENG at SYDVM1)
  1157. Subject: Rexx Examples for pipe
  1158. Hi,
  1159. I have a customer who would like to be able to have a rexx procedure
  1160. write information to a named pipe which was created by a 'C' program.
  1161. Any information on how to do this or examples would be great.
  1162.  
  1163. Dave Ng
  1164. PSG - Melbourne
  1165.  
  1166. ----- OS2REXX CFORUM appended at 11:46:55 on 92/06/11 GMT (by MCGUIRE at GDLVM7)
  1167. Subject: Rexx Examples for pipe
  1168. Ref:     Append at 09:38:50 on 92/06/11 GMT (by DAVENG at SYDVM1)
  1169.  
  1170. Trivial actually.  Just use the standard Rexx I/O functions:
  1171.  
  1172.    call stream '\PIPE\MYPIPE', 'C', 'OPEN'    /* open the pipe */
  1173.    call lineout '\PIPE\MYPIPE', request       /* send the request */
  1174.    reply = linein('\PIPE\MYPIPE')             /* get a reply back */
  1175.    call stream '\PIPE\MYPIPE', 'C', 'CLOSE'   /* disconnect from the pipe */
  1176.  
  1177. Rick McGuire - SAA Rexx Development, Endicott
  1178.  
  1179. ----- OS2REXX CFORUM appended at 12:23:56 on 92/06/11 GMT (by NAAD356 at OS2CUST)
  1180. Subject: REXX as an application driver for DTL
  1181.  
  1182. Is is possible to use REXX to drive applications for OS/2 written using
  1183. Dialog tag language?  I did not see REXX listed in the ISPF/DTL manual
  1184. as being used for this?
  1185.  
  1186. ----- OS2REXX CFORUM appended at 12:40:17 on 92/06/11 GMT (by SCHOLICH at SDFVM003)
  1187. Subject: Rexx Examples for pipe
  1188. Ref:     Append at 11:46:55 on 92/06/11 GMT (by MCGUIRE at GDLVM7)
  1189.  
  1190. Hello Rick !
  1191. I've tried your example for pipe.
  1192. I'm soory, but it does'nt work for me !
  1193. The Result of the 'open' - statement is 'NOTREADY:3'
  1194. (the system cannot find the path specified)
  1195. What's my mistake?
  1196.  
  1197. Juergen Scholich  (SCHOLICH at SDFVM003)  Sindelfingen, Germany
  1198.  
  1199. ----- OS2REXX CFORUM appended at 13:46:14 on 92/06/11 GMT (by MCGUIRE at GDLVM7)
  1200. Subject: Rexx Examples for pipe
  1201. Ref:     Append at 12:40:17 on 92/06/11 GMT (by SCHOLICH at SDFVM003)
  1202.  
  1203. Well, it will only work if the C program has already created the named pipe.
  1204.  
  1205. Rick McGuire - SAA Rexx Development, Endicott
  1206.  
  1207. ----- OS2REXX CFORUM appended at 13:55:37 on 92/06/11 GMT (by XXNOVA24 at TORVMCOP)
  1208. Subject: Rexx Examples for pipe
  1209. Ref:     Append at 12:40:17 on 92/06/11 GMT (by SCHOLICH at SDFVM003)
  1210.  
  1211. Juergen,
  1212. Did you put two backslash  before the PIPE ? \\pipe\mypipe
  1213.  
  1214. Geza Szivos
  1215. NOVACOR Chemicals (403)-290-6583
  1216.  
  1217. ----- OS2REXX CFORUM appended at 21:49:08 on 92/06/11 GMT (by JDCANON at CHGVMIC1)
  1218. Subject: PMREXX and "REXX procedure has ended" message
  1219. Ref:     Append at 13:09:58 on 92/06/03 GMT (by SAMI3QU at OS2CUST)
  1220.  
  1221. Modifying the PMREXX source isn't that hard.  I had the same question
  1222. and got the following answer:
  1223.  
  1224.    Go to line 974 in PMREXX.C
  1225.    delete everything from
  1226.    WinSendMsg(.....
  1227.    to
  1228.    }
  1229.    (The squiggly bracket in line 981)
  1230.  
  1231.    Replace all that with one line that reads
  1232.  
  1233.       WinPostMsg(hwndClient, WM_CLOSE, NULL, NULL);
  1234.  
  1235.    Then save and recompile. Your new PMREXX will *QUIT* when the
  1236.    Rexx Exec Exits. Save an old copy for debug. Use the new one
  1237.    for production.
  1238.  
  1239. A tip of the REXX hat to Greg Forney who provided this answer for me!
  1240.  
  1241. Joel Canon -- Bloomington, Illinois
  1242.  
  1243. ----- OS2REXX CFORUM appended at 11:28:53 on 92/06/15 GMT (by SCHOLICH at SDFVM003)
  1244. Subject: Rexx Examples for pipe
  1245. Ref:     Append at 13:55:37 on 92/06/11 GMT (by XXNOVA24 at TORVMCOP)
  1246.  
  1247. Thank you Geza, thank you Rick.
  1248. By the way, is there any tool, that allowes the creation of a named pipe
  1249. by a rexx-program ??
  1250.  
  1251. Juergen Scholich  (SCHOLICH at SDFVM003)  Sindelfingen, Germany
  1252.  
  1253. ----- OS2REXX CFORUM appended at 11:52:26 on 92/06/15 GMT (by 78819237 at EHONE)
  1254. Subject: Rexx Examples for pipe
  1255. Ref:     Append at 11:28:53 on 92/06/15 GMT (by SCHOLICH at SDFVM003)
  1256.  
  1257. I thought that was a built in function: RxQueue
  1258. With RxQueue you can Create queues etc.
  1259.  
  1260. Michael Dag, TEAM OS/2 Netherlands
  1261.  
  1262. ----- OS2REXX CFORUM appended at 13:41:18 on 92/06/15 GMT (by MRTOM at YKTVMV)
  1263. Subject: Rexx Examples for pipe
  1264. Ref:     Append at 11:52:26 on 92/06/15 GMT (by 78819237 at EHONE)
  1265.  
  1266. RXQUEUE allows you to create queues, not pipes.
  1267.  
  1268. Tom
  1269.  
  1270. ----- OS2REXX CFORUM appended at 13:51:41 on 92/06/15 GMT (by PMUELLR at CARVM3)
  1271. Subject: Rexx Examples for pipe
  1272. Ref:     Append at 13:41:18 on 92/06/15 GMT (by MRTOM at YKTVMV)
  1273.  
  1274. Even still, the queues rexx allows access to are distinct from the
  1275. OS/2 queues from the Dos...Queue() APIs.  You can't mix & match 'em.
  1276.  
  1277. Patrick Mueller - IBM Cary
  1278.  
  1279. ----- OS2REXX CFORUM appended at 13:59:54 on 92/06/15 GMT (by CONT00 at LEXVMK)
  1280. Subject: Rexx Examples for pipe
  1281. Ref:     Append at 13:41:18 on 92/06/15 GMT (by MRTOM at YKTVMV)
  1282.  
  1283. Are those "internal REXX Queues" (available ONLY from a REXX program in
  1284. ONE process) or "standard" OS/2 queues ?
  1285.  
  1286. Gregory Czaja, Lexington 8-545-3311  1992/06/15  09:58
  1287.  
  1288. ----- OS2REXX CFORUM appended at 14:56:48 on 92/06/15 GMT (by 78819237 at EHONE)
  1289. Subject: Rexx Examples for pipe
  1290. Ref:     Append at 13:41:18 on 92/06/15 GMT (by MRTOM at YKTVMV)
  1291.  
  1292. Tom, thanks for setting me straight... back to the books for me :-(
  1293.  
  1294. Michael Dag   TEAM OS/2 Netherlands
  1295.  
  1296. ----- OS2REXX CFORUM appended at 18:29:47 on 92/06/15 GMT (by TEMP19GC at CLTVM1)
  1297. Subject: Verify
  1298.  
  1299. I am trying to search a string for a substring.  I used verify but I want
  1300. the substring to not only be contained in the string but also appear in
  1301. the same order or format.  i.e.
  1302.  
  1303.        OptionalSystemUtilities=2,3,10,12 and I am searching for the
  1304. substring 13.  Verify will say that 13 is a substring of this.
  1305.  
  1306. Does anyone know of any other tools or commands?
  1307.  
  1308. Thanks,
  1309.  
  1310. Aubrey Hawes
  1311.  
  1312. ----- OS2REXX CFORUM appended at 20:03:54 on 92/06/15 GMT (by MCGUIRE at GDLVM7)
  1313. Subject: Verify
  1314. Ref:     Append at 18:29:47 on 92/06/15 GMT (by TEMP19GC at CLTVM1)
  1315.  
  1316. I think you want the Pos() builtin function:
  1317.  
  1318.   position = pos('13', 'OptionalSystemUtilities=2,3,10,12')
  1319.  
  1320. Rick McGuire - SAA Rexx Development, Endicott
  1321.  
  1322. ----- OS2REXX CFORUM appended at 20:16:25 on 92/06/15 GMT (by GBFORNEY at WASVMIC5)
  1323. Subject: Verify
  1324. Ref:     Append at 18:29:47 on 92/06/15 GMT (by TEMP19GC at CLTVM1)
  1325.  
  1326. I have never heard of verify, but pos('13',OptionSystemUtilites)
  1327. should do what you want. It would return a value of zero for
  1328. your example.
  1329.  
  1330. Greg Forney - DVSC
  1331.  
  1332. ----- OS2REXX CFORUM appended at 21:03:51 on 92/06/15 GMT (by MRTOM at YKTVMV)
  1333. Subject: Verify
  1334. Ref:     Append at 18:29:47 on 92/06/15 GMT (by TEMP19GC at CLTVM1)
  1335.  
  1336. Cmd = 'OptionalSystemUtilities=2,3,10,12'
  1337. parse var Cmd '=' Opts
  1338. if wordpos('13', translate(Opts, ' ', ',')) > 0
  1339.   then say '13 was specified.'
  1340.   else say 'No 13 for you.'
  1341.  
  1342. Tom
  1343.  
  1344. ----- OS2REXX CFORUM appended at 22:24:20 on 92/06/15 GMT (by MRTOM at YKTVMV)
  1345. Subject: Verify
  1346. Ref:     Append at 20:03:54 on 92/06/15 GMT (by MCGUIRE at GDLVM7)
  1347.          Append at 20:16:25 on 92/06/15 GMT (by GBFORNEY at WASVMIC5)
  1348.  
  1349. Rick, you should know better than that!  If OptionSystemUtilities
  1350. = '1,3,10,12,139, you'll get a false hit.
  1351.  
  1352. Tom
  1353.  
  1354. ----- OS2REXX CFORUM appended at 22:50:11 on 92/06/15 GMT (by PMUELLR at CARVM3)
  1355. ..... OS2REXX CFORUM modified at 22:53:50 on 92/06/15 GMT (by PMUELLR at CARVM3)
  1356.  
  1357. ..removed redundant append
  1358.  
  1359. ----- OS2REXX CFORUM appended at 06:35:48 on 92/06/16 GMT (by SCHOLICH at SDFVM003)
  1360. Subject: Verify
  1361. Ref:     Append at 18:29:47 on 92/06/15 GMT (by TEMP19GC at CLTVM1)
  1362.  
  1363. I think, that the POS - funktion will work for you.
  1364. The example should be:
  1365. Exist = POS("13", string)
  1366.  
  1367. Juergen Scholich  (SCHOLICH at SDFVM003)  Sindelfingen, Germany
  1368.  
  1369. ----- OS2REXX CFORUM appended at 10:46:33 on 92/06/16 GMT (by VERSTEEG at UITVM1)
  1370. Subject: Verify
  1371. Ref:     Append at 18:29:47 on 92/06/15 GMT (by TEMP19GC at CLTVM1)
  1372.  
  1373. Another alternative is 'FIND'.
  1374. It requires the words be separated by blanks though.
  1375. str = translate(string," ",",")
  1376. exist = find(str,'13')
  1377. /* exist has word number in str or 0 */
  1378.  
  1379. Anton Versteeg - ESAT PWS CoC Uithoorn, NL
  1380.  
  1381. ----- OS2REXX CFORUM appended at 11:16:14 on 92/06/16 GMT (by MCGUIRE at GDLVM7)
  1382. Subject: Verify
  1383. Ref:     Append at 22:24:20 on 92/06/15 GMT (by MRTOM at YKTVMV)
  1384.  
  1385. Except I believe he wanted the false hit in that situation.  Verify would
  1386. give a true hit, since it would search for either a 1 or a 3.
  1387.  
  1388. Rick McGuire - SAA Rexx Development, Endicott
  1389.  
  1390. ----- OS2REXX CFORUM appended at 12:58:02 on 92/06/16 GMT (by MRTOM at YKTVMV)
  1391. Subject: Verify
  1392. Ref:     Append at 10:46:33 on 92/06/16 GMT (by VERSTEEG at UITVM1)
  1393.  
  1394. FIND isn't in OS/2 REXX.
  1395.  
  1396. Tom
  1397.  
  1398. ----- OS2REXX CFORUM appended at 12:59:52 on 92/06/16 GMT (by MRTOM at YKTVMV)
  1399. Subject: Verify
  1400. Ref:     Append at 11:16:14 on 92/06/16 GMT (by MCGUIRE at GDLVM7)
  1401.  
  1402. Mmm.  I took it to mean that they were looking to see if the number
  1403. was in the comma delimited list.  Guess the appender will have to
  1404. clarify.
  1405.  
  1406. Tom
  1407.  
  1408. ----- OS2REXX CFORUM appended at 14:23:27 on 92/06/16 GMT (by TEMP19GC at CLTVM1)
  1409. Subject: Verify
  1410. Ref:     Append at 12:59:52 on 92/06/16 GMT (by MRTOM at YKTVMV)
  1411.  
  1412. I was trying to see if OptionSystemUtilities had the number 13 as one of
  1413. the numbers set after the equal.  I am using the POS command and it is
  1414. working fine, because all I care about is whether or not 13 is in the
  1415. string.
  1416.  
  1417. Thanks,
  1418.  
  1419. Aubrey Hawes
  1420.  
  1421. ----- OS2REXX CFORUM appended at 16:51:39 on 92/06/16 GMT (by MRTOM at YKTVMV)
  1422. Subject: Verify
  1423. Ref:     Append at 14:23:27 on 92/06/16 GMT (by TEMP19GC at CLTVM1)
  1424.  
  1425. So you DON'T care that if the string is:
  1426. OptionSystemUtilities = 14,26
  1427.  
  1428. and you test for "4" you'll get a hit?  POS will find 1 above;  from
  1429. what you've appended so far, I don't think you want it to unless
  1430. the string is something like:
  1431. OptionSystemUtilities = 4,14,26
  1432.  
  1433. Tom
  1434.  
  1435. ----- OS2REXX CFORUM appended at 17:53:42 on 92/06/16 GMT (by TEMP19GC at CLTVM1)
  1436. Subject: Verify
  1437. Ref:     Append at 16:51:39 on 92/06/16 GMT (by MRTOM at YKTVMV)
  1438.  
  1439. Ok you are right.  Got any other ideas.
  1440.  
  1441. Thanks,
  1442.  
  1443. Aubrey Hawes
  1444.  
  1445. ----- OS2REXX CFORUM appended at 20:44:27 on 92/06/16 GMT (by IL22993 at OS2CUST)
  1446. Subject: can REXX "open" an object??
  1447.  
  1448. Is there a method within rexx to "start" or "open" an object either on the
  1449. desktop or within a folder?  I know for example that you can add an
  1450. object to the desktop memu by through the menu settings, and then open
  1451. the object, as opposed to a program...  e.g. adding "OS/2 Window" to the menu
  1452. v.s. adding "CMD.EXE" to the menu.    The big advantage is that any "settings"
  1453. applied to the object are kept.
  1454.  
  1455. Now... If there were some way for me to open a program object from REXX rather
  1456. than the .exe or .bat file itself, there might be a way for us to get settings
  1457. (DOS Version, memory, etc.) to be set correctly for the object rather than use
  1458. the system defaults.
  1459.  
  1460. I am not against writing a little C code if necessary....  Sure would be a nice
  1461. extension  to the Rexx Utilities!  (My toolkit is on order!)
  1462.  
  1463. Does anyone have any suggestions?
  1464.  
  1465. Thanks...
  1466.  
  1467. George Clark
  1468.  
  1469. ----- OS2REXX CFORUM appended at 23:00:22 on 92/06/16 GMT (by MRTOM at YKTVMV)
  1470. Subject: Verify
  1471. Ref:     Append at 17:53:42 on 92/06/16 GMT (by TEMP19GC at CLTVM1)
  1472.          Append at 21:03:51 on 92/06/15 GMT (by MRTOM at YKTVMV)
  1473.  
  1474. Sure!  See my referenced append.
  1475.  
  1476. Tom
  1477.  
  1478. ----- OS2REXX CFORUM appended at 11:12:52 on 92/06/17 GMT (by MCGUIRE at GDLVM7)
  1479. Subject: can REXX "open" an object??
  1480. Ref:     Append at 20:44:27 on 92/06/16 GMT (by IL22993 at OS2CUST)
  1481.  
  1482. There aren't any WorkPlace Shell APIs for opening a view of an object,
  1483. although every object has a wpOpen method.  I don't think a Rexx program can
  1484. directly access the methods, but you might be able to write a WPS object that
  1485. Rexx programs can send messages via a named pipe or queue.
  1486.  
  1487. Rick McGuire - SAA Rexx Development, Endicott
  1488.  
  1489. ----- OS2REXX CFORUM appended at 17:30:11 on 92/06/17 GMT (by TRAUTMAN at PKEDVM8)
  1490. Subject: can REXX "open" an object??
  1491. Ref:     Append at 11:12:52 on 92/06/17 GMT (by MCGUIRE at GDLVM7)
  1492.  
  1493. Check out the options on the START command.  I belive something like
  1494. 'START /PGM "The Icon Text for Program"  will open the object
  1495. that has the name "The Icon Text for Program".
  1496.  
  1497. Bill Trautman
  1498.  
  1499. ----- OS2REXX CFORUM appended at 20:02:14 on 92/06/17 GMT (by MRTOM at YKTVMV)
  1500. Subject: can REXX "open" an object??
  1501. Ref:     Append at 17:30:11 on 92/06/17 GMT (by TRAUTMAN at PKEDVM8)
  1502.  
  1503. I think the user wanted to open an object, such as the OS/2 System
  1504. folder, not start a program.
  1505.  
  1506. Tom
  1507.  
  1508. ----- OS2REXX CFORUM appended at 22:13:01 on 92/06/17 GMT (by MAGUIRET at RHQVM21)
  1509. Subject: Rexx not freeing DLL for external function
  1510. Ref:
  1511.  
  1512. I'm having some trouble with REXX on OS2V2.  I do an RxFuncAdd followed
  1513. by some use of the function and eventually an RxFuncDrop.  The problem
  1514. is that when I try to reLink the DLL the linker can't open the run
  1515. file (i.e. the DLL).  Am I doing something wrong?  BTW, I get a
  1516. return code 0 from RxFuncDrop.  Is this WAD or FEECHUR?
  1517.  
  1518. Tom Maguire
  1519.  
  1520. ----- OS2REXX CFORUM appended at 11:23:14 on 92/06/18 GMT (by MCGUIRE at GDLVM7)
  1521. Subject: Rexx not freeing DLL for external function
  1522. Ref:     Append at 22:13:01 on 92/06/17 GMT (by MAGUIRET at RHQVM21)
  1523.  
  1524. "Working As Designed".  You need to exit any sessions that used the function
  1525. DLL to get the system loader support to remove the loaded copy for you.
  1526.  
  1527. Rick McGuire - SAA Rexx Development, Endicott
  1528.  
  1529. ----- OS2REXX CFORUM appended at 12:46:57 on 92/06/18 GMT (by CONT00 at LEXVMK)
  1530. Subject: Rexx not freeing DLL for external function
  1531. Ref:     Append at 11:23:14 on 92/06/18 GMT (by MCGUIRE at GDLVM7)
  1532.  
  1533. Rick, could you please check on this again... When using LINK (16 bit)
  1534. it does really complain and I have to exit, but when I use LINK386 (32)
  1535. I don't have to and the DLL gets relinked. Is there a difference ?
  1536.  
  1537. Gregory Czaja, Lexington 8-545-3311  1992/06/18  08:44
  1538.  
  1539. ----- OS2REXX CFORUM appended at 20:15:52 on 92/06/18 GMT (by TMARTIN at NHBVM4)
  1540. Subject: Verify
  1541. Ref:     Append at 23:00:22 on 92/06/16 GMT (by MRTOM at YKTVMV)
  1542.  
  1543. You can also use parse;  eg:
  1544.  
  1545. /* demonstrate use of parse */
  1546. arg z
  1547. interpret 'parse value " A=42 B=47 C=99 'z'=default " with "' z'=" res .'
  1548. say res
  1549. exit
  1550.  
  1551. If z = "A", this says 42.  If z is B or C, this says 47 or 99.
  1552. If z is something else, this says "default".
  1553.  
  1554.                     Tim Martin  (TMARTIN @ NHBVM4)  1992/06/18 21:06 BST
  1555.  
  1556. ----- OS2REXX CFORUM appended at 21:37:03 on 92/06/18 GMT (by MAAV7IB at OS2CUST)
  1557. Subject: SYSGETEA and SYSPUTEA Examples have undocumented hex information
  1558.  
  1559. The SysGetEA and SysPutEA examples have special hex information that is not
  1560. documented in the example.  Where can I find what that information specifies?
  1561. When used on a file that has EA info stored by the system editor, the same
  1562. hex info is stored in the ".type" value.
  1563.  
  1564. The SysGetEA example is incorrect.  It does not have balanced parenthesis.
  1565.  
  1566. Why does the SysPutEA use "TYPE" for the EA name and SysGetEA uses ".type"?
  1567.  
  1568. Kevin Miller
  1569.  
  1570. ----- OS2REXX CFORUM appended at 02:37:28 on 92/06/19 GMT (by SDETWEIL at DETVMIC4)
  1571. Subject: Rexx not freeing DLL for external function
  1572. Ref:     Append at 12:46:57 on 92/06/18 GMT (by CONT00 at LEXVMK)
  1573.  
  1574. Are you linking a C-SET/2 built DLL? If so, it uses the new OS/2 2.0
  1575. InitTerm function and will be freed when DosFreeModuled. DLLs
  1576. built with IBM or MS C register an Exitlist which will NOT
  1577. allow the module to be freed UNTIL ALL using processes (CMD.EXE)
  1578. end..
  1579.  
  1580. Sam
  1581.  
  1582. ----- OS2REXX CFORUM appended at 12:37:10 on 92/06/19 GMT (by MIKELAMB at KGNVMC)
  1583. ..... OS2REXX CFORUM modified at 14:06:29 on 92/07/29 GMT (by MIKELAMB at KGNVMC)
  1584. Subject: REXXUTIL Information and Samples
  1585.  
  1586. The following attempts to better explain some of the powerful features
  1587. provided by OS/2 V2's dynamic link library; REXXUTIL.DLL (Rexx utility
  1588. functions). REXXUTIL functions are described in the online 'REXX Information'
  1589. reference and the 'OS/2 2.0 Technical Library Procedures Language/2 REXX
  1590. Reference' publication (order number S10G-6268). The information following is
  1591. intended to provide a more detailed description of some of the functions.
  1592.  
  1593. One should realize that many of the functions provided by REXXUTIL have
  1594. origins with Presentation Manager WinXXX calls. The 'OS/2 Technical
  1595. Library Presentation Manager Programming Reference Vol2' publication
  1596. (order number S10G-6265) can be reviewed for more information.
  1597.  
  1598. Some of the functions used/explained:
  1599.  
  1600. SysIni:
  1601. Using REXXUTIL's SysIni function one can modify many settings of the WorkPlace
  1602. Shell as well as change other applications settings that make use of *.INI
  1603. files such as the system OS2.INI and OS2SYS.INI.
  1604.  
  1605. SysCreateObject: (PM WinCreateObject - Create Workplace Object)
  1606. Using REXXUTIL's SysCreateObject function one can create various objects;
  1607. like folders, programs, and shadow objects using Rexx. This section for the
  1608. most part includes parameter information which was gathered together from
  1609. various sources of information.
  1610.  
  1611. SysSetObjectData: (PM WinSetObjectData - Set Object Data)
  1612. Using REXXUTIL's SysSetObjectData function one can change an objects
  1613. characteristics (of an already created object, if you know its objectid).
  1614.  
  1615. SysDestroyObject: (PM WinDestroyObject - Destroy Workplace Object)
  1616. Using REXXUTIL's SysDestroyObject one can delete an object created if you
  1617. know its objectid.
  1618.  
  1619. Misc Notes:
  1620. If one views the *.RC files located in your bootdrive:\OS2 directory you
  1621. can learn a lot about the various INI settings and folder structure.
  1622. Review INI.RC and INISYS.RC files, they are used to create your OS2.INI
  1623. and OS2SYS.INI files.
  1624.  
  1625. Some of REXXUTIL's functions are only available when using the very latest
  1626. REXX20 PACKAGE which consists of the very latest REXX fixes and enhancements
  1627. for OS/2 V2. So should you have problems running any of the sample programs
  1628. you should make sure your system has the vary latest REXX20 updates.
  1629.  
  1630. If anyone discovers other parameters or other "hidden" features of
  1631. any of the functions discussed, please share your discovery. I'll try to
  1632. update the information as I receive it.
  1633.  
  1634. Thanks...
  1635. Michael Lamb MIKELAMB(KGNVMC)
  1636. Workstation Technical Support
  1637. Kingston NY
  1638.  
  1639. Change Log:
  1640.   04/30/92 - Added information about DuplicateFlag parm
  1641.            - Added more setup string information from manuals
  1642.   06/02/92 - Added information about breaking Title line character "^"
  1643.            - Added information about adding multiple DOS_DEVICE statements
  1644.            - Added code to SHADOW.CMD to make shadow object of a file
  1645.   !!NOTE!! - The REXXOS2 fixes are required to make some of
  1646.              the newer samples work properly.
  1647.   06/30/92 - Added information regarding two new REXXUTIL functions:
  1648.              SysSetObjectData and SysDestroyObject, also two new
  1649.              samples STARTDOS, BOOTDOS (Thanks to Rick McGuire)
  1650.   07/13/92 - Reorganized the way the material is presented. Also added more
  1651.              sample Rexx routines REBUILD, OBJCLASS and LPTADD, descriptions
  1652.              follow. Also changed parm CONCURRENTVIEW to CCVIEW (Thanks
  1653.              Dan Kehn, Felix Sawicki)
  1654.   07/15/92 - Updated entire document as I mistakenly truncated it at 80
  1655.              characters. Rewrote some sample Rexx routines so they do not
  1656.              extend beyond 80 characters. Also updated the SysSetObjectData
  1657.              description to show how can open an object (Thanks Rick). Added
  1658.              information about creating multi-line titles, carat works for
  1659.              two line titles but not more than 2.
  1660.              New samples, OBJECTID and FONTS included, descriptions follow.
  1661.   07/29/92 - Corrected an error I made when I broke the setup lines into
  1662.              multiple lines. I needed to add ||'s to make sure they
  1663.              concatenated without spaces (Thanks Rick). Also added
  1664.              information regarding changing some System Settings (added
  1665.              new section after sample Rexx code). Also added warning
  1666.              in REBUILD.CMD sample about replacing Folder objects. Also
  1667.              added new sample ICONRES.CMD which builds a folder containing
  1668.              many of the OS/2 V2 installed icons using system DLL files.
  1669.  
  1670. This append consists of multiple pieces of information:
  1671.  
  1672. 1) Large block of text containing information that pertains to the subject.
  1673.    (TEXT INFORMATION)
  1674. 2) Sample Rexx code, some complete programs, others code fragments:
  1675.  - (FOLDER.CMD)
  1676.    Creates a folder and program objects in the folder
  1677.  - (SHADOW.CMD)
  1678.    Creates shadows of objects
  1679.  - (FLDSHAD.CMD)
  1680.    Creates a folder, then program object in the folder, then place a shadow
  1681.    of the program object on the desktop.
  1682.  - (STARTDOS.CMD)
  1683.    Starts a DOS program using specific DOS VDM settings.
  1684.  - (BOOTDOS.CMD)
  1685.    Starts a DOS session, booting from a specific DOS image with
  1686.    specific DOS VDM settings.
  1687.  - (REBUILD.CMD)
  1688.    Allows one to rebuild OS/2 system objects, like MAKEINI does.
  1689.  - (LPTADD.CMD)
  1690.    Code using SysIni to add LPT4-9 ports.
  1691.  - (OBJECTID.CMD)
  1692.    Code using SysIni to list OBJECTIDs known to the WorkPlace Shell
  1693.  - (FONTS.CMD)
  1694.    Code using SysIni to list installed fonts.
  1695.  - ICONRES.CMD
  1696.    Code building a folder containing many of the various icons found in
  1697.    installed DLL files for OS/2 V2. Demonstrates use of setup string
  1698.    parameter ICONRESOURCE.
  1699. 3) Code Fragments
  1700.  - (SYSSET)
  1701.    Shows using SysIni to toggle various System Settings
  1702.  
  1703. ((BEGIN TEXT INFORMATION))
  1704. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  1705.  
  1706. -- Help information regarding the SysCreateObject function of REXXUTIL --
  1707.  
  1708. Function: SysCreateObject
  1709. Syntax:
  1710. result=SysCreateObject(classname, title, location <,setup>, <,duplicateflag>)
  1711.  
  1712.  classname:The name of the object class.
  1713.  
  1714.  title:    The object title.
  1715.  
  1716.  location: The object location.  This can be specified as either a
  1717.            descriptive path (for example, OS/2 System Folder\System
  1718.            Configuration) or a file system path (for example,
  1719.            C:\bin\mytools).
  1720.  
  1721.  setup:    A WinCreateObject setup string.
  1722.  
  1723.  duplicateflag: This parameter indicates what action should be taken
  1724.            when the Setup string specifies an object ID, and an object with
  1725.            that object ID already exists. If the setup string does not give
  1726.            an object ID, a duplicate object will be created.
  1727.  
  1728.  result    The return code from WinCreateObject. This returns 1 (TRUE) if the
  1729.            object was created and 0 (FALSE) if the object was not created.
  1730.  
  1731.  Purpose:  Create a new instance of an object class.
  1732.  
  1733. -- Help information regarding the SysSetObjectData function of REXXUTIL --
  1734.  
  1735. Function: SysSetObjectData
  1736. Syntax:
  1737. result=SysSetObjectData(name, setup)
  1738.  
  1739.  name:     The object name.  This can be specified as an object id (for
  1740.            example <WP_DESKTOP>) or as a fully specified file name.
  1741.  
  1742.  setup:    A WinCreateObject setup string.
  1743.  
  1744.  Purpose:  Alter the settings of an existing object. Can also be used to
  1745.            open an instance of an object:
  1746.                                  /* open up the system folder */
  1747.            call SysSetObjectData '<WP_OS2SYS>', 'OPEN=DEFAULT;'
  1748.  
  1749. See the description of the SysCreateObject location and setup strings
  1750. following for an explanation of the parameters.
  1751.  
  1752. -- Help information regarding the SysDestroyObject function of REXXUTIL --
  1753.  
  1754. Function: SysDestroyObject
  1755. Syntax:
  1756. result=SysDestroyObject(name)
  1757.  
  1758.  name:     The object name.  This can be specified as an object id (for
  1759.            example <WP_DESKTOP>) or as a fully specified file name.
  1760.  
  1761.  Purpose:  Destroys an existing object.
  1762.  
  1763. See the description of the SysCreateObject location parameter
  1764. following for an explanation of the object name.
  1765.  
  1766. --SysCreateObject Parms------------------------------------------------------
  1767.  
  1768. The SysCreateObject parameters are now explained in more detail.
  1769.  
  1770. Remember syntax is...
  1771. result=SysCreateObject(classname, title, location <,setup>, <,duplicateflag>)
  1772.  
  1773. classname:
  1774.   A registered object class defined to the system. Of particular interest are
  1775.   the WPFolder/WPProgram/WPShadow classes. Note using the sample Rexx code
  1776.   included in the SysQueryClassList function help screen one can list all
  1777.   of the registered classes:
  1778.  
  1779.   call SysQueryClassList "list."
  1780.   do i = 1 to list.0
  1781.      say 'Class' i 'is' list.i
  1782.   end
  1783.  
  1784. title:
  1785.   Easy one, the objects title you want to use. If you wish to break the title
  1786.   line use the carat "^" symbol in the title. Ex. 'First line^Second Line'
  1787.   This works to break a title into two lines. However to break a title into
  1788.   more than two lines you need to separate the title lines with a hex 0A
  1789.   (line-feed) character.
  1790.   Rexx example:
  1791.   h0A='0A'X
  1792.   title='First'h0A'Second'h0A'Third'
  1793.  
  1794. location:
  1795.   The objects location can be specified as either a descriptive path (for
  1796.   example, OS/2 System Folder\System Configuration) or a file system path
  1797.   (for example, C:\bin\mytools). However by looking at the INI.RC file one
  1798.   can see a use of other "locations", such as <WP_DESKTOP>. If this is used
  1799.   as a location then your object will reside on the WorkPlace Shell desktop.
  1800.   If you are creating a folder or program object you should make sure you use
  1801.   the setup string option and give that folder a unique OBJECTID. We'll see
  1802.   how this works later.
  1803.  
  1804.   HINTS: Here are some predefined object ids of system folders. Also if you
  1805.          are thinking of placing an object in the Startup Folder <WP_START>,
  1806.          make it a shadow of an object.
  1807.          <WP_DESKTOP>   The Desktop.
  1808.          <WP_START>     The Startup folder.
  1809.          <WP_OS2SYS>    The System folder.
  1810.          <WP_TEMPS>     The Templates folder.
  1811.          <WP_CONFIG>    The System Setup folder.
  1812.          <WP_INFO>      The Information folder.
  1813.          <WP_DRIVES>    The Drives folder.
  1814.          <WP_NOWHERE>   The hidden folder.
  1815.  
  1816. setup:
  1817.   This field needs the most explaining, a larger section following details
  1818.   many of the available setupstring parameters. The setupstring field contains
  1819.   a series of "keyname=value" pairs separated by semi-colons that change the
  1820.   behavior of an object. Each object class documents its keynames and the
  1821.   parameters it expects to see.
  1822.  
  1823. duplicateflag:
  1824.   There are three possible values for this parameter:
  1825.   FailIfExists - No object should be created if an object with the
  1826.       given object already exists. This is the default and maps to the
  1827.       PM creation flag, CO_FAILIFEXISTS
  1828.   ReplaceIfExists - If an object with the given object ID already exists,
  1829.       the existing object should be replaced. Maps to the PM creation
  1830.       flag, CO_REPLACEIFEXISTS.
  1831.   UpdateIfExists - If an object with the given object ID already exists,
  1832.       the existing object should be updated with the new information.
  1833.       Maps to the creation flag, CO_UPDATEIFEXISTS.
  1834.   (Only the first character is required/examined, i.e. F, R, or U)
  1835.  
  1836. ALL parameters have safe defaults, so it is never necessary to pass
  1837. unnecessary parameters to an object.
  1838.  
  1839. --Setup Strings--------------------------------------------------------------
  1840.  
  1841.   What follows are both WPFolder and WPProgram setup string parameters.
  1842.   Their various key names, values and a short description follow
  1843.   each item. The <<xxx>> item is there to give you an idea of what
  1844.   Workplace Shell settings "page" you would find this information on.
  1845.  
  1846. *********************************
  1847. ***WPFolder setup string parms***
  1848. *********************************
  1849. KEYNAME      VALUE           Description
  1850. -----------------------------------------------------------------------------
  1851. <<View>>
  1852. OPEN         ICON            Open icon view when object is created.
  1853.              TREE            Open tree view when object is created.
  1854.              DETAILS         Open details view when object is created.
  1855. ICONVIEW     s1[,s2,...sn]   Set icon view to specified style(s).
  1856. TREEVIEW     s1[,s2,...sn]   Set tree view to specified style(s).
  1857. DETAILSVIEW  s1[,s2,...sn]   Set details view to specified style(s).
  1858. (styles)     FLOWED          flowed list items
  1859.              NONFLOWED       non-flowed list items
  1860.              NONGRID         non-gridded icon view
  1861.              NORMAL          normal size icons
  1862.              MINI            small icons
  1863.              INVISIBLE       no icons
  1864.              LINES           lines in tree view
  1865.              NOLINES         no lines in tree view
  1866. <<Background>>
  1867. BACKGROUND   filename        Sets the folder background. filename is the
  1868.                              name of a file in the \OS2\BITMAP directory
  1869.                              of the boot drive.
  1870. <<File>>
  1871. WORKAREA     YES             Make the folder a Workarea folder
  1872. <<Window>>
  1873. MINWIN       HIDE            Views of this object will hide when their
  1874.                              minimize button is selected.
  1875.              VIEWER          Views of this object will minimize to the
  1876.                              minimized window viewer when their minimize
  1877.                              button is selected.
  1878.              DESKTOP         Views of this object will minimize to the
  1879.                              Desktop when their minimize button is selected.
  1880. VIEWBUTTON   HIDE            Views of this object will have a hide button
  1881.                              as opposed to a minimize button.
  1882.              MINIMIZE        Views of this object will have a minimize button
  1883.                              as opposed to a hide button.
  1884. CCVIEW       YES             New views of this object will be created every
  1885.                              time the user selects open.
  1886.              NO              Open views of this object will resurface when
  1887.                              the user selects open.
  1888. <<General>>
  1889. ICONFILE     filename        This sets the object's icon.
  1890. ICONRESOURCE id,module       This sets the object's icon. 'id' is the
  1891.                              identity of an icon resource in the 'module'
  1892.                              dynamic link library (DLL).
  1893. ICONPOS      x,y             This sets the object's initial icon position.
  1894.                              The x and y values represent the position in
  1895.                              the object's folder in percentage coordinates.
  1896. TEMPLATE     YES             Creates object as a template.
  1897.              NO              Resets objects template property.
  1898. -----------------------------------------------------------------------------
  1899.  
  1900. **********************************
  1901. ***WPProgram setup string parms***
  1902. **********************************
  1903. KEYNAME      VALUE           Description
  1904. -----------------------------------------------------------------------------
  1905. <<Program>>
  1906. EXENAME      filename        Sets the name of the program
  1907. PARAMETERS   params          Sets the parameters list, which may
  1908.                              include substitution characters
  1909. STARTUPDIR   pathname        Sets the working directory
  1910. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  1911. <<Sessions>>
  1912. PROGTYPE     FULLSCREEN      Sets the session type to OS/2 full screen
  1913.              PM              Sets the session type to PM
  1914.              SEPARATEWIN     Sets the session type to WIN-OS2 window
  1915.                              running in a separate VDM.
  1916.              VDM             Sets the session type to DOS full screen
  1917.              WIN             Sets the session type to WIN-OS2 full screen
  1918.              WINDOWABLEVIO   Sets the session type to OS/2 windowed
  1919.              WINDOWEDVDM     Sets the session type to DOS windowed
  1920.              WINDOWEDWIN     Sets the session type to WIN-OS2 windowed
  1921. MINIMIZED    YES             Start program minimized
  1922. MAXIMIZED    YES             Start program maximized
  1923. NOAUTOCLOSE  YES             Leaves the window open upon program termination.
  1924.              NO              Closes the window when the program terminates.
  1925. -DOS Settings-
  1926. NOTES:
  1927. - To change these values you use SET keyname=
  1928.   Example:   SET DOS_FILES=45;SET DOS_HIGH=1
  1929.   Also for some use values of 1 for ON, 0 for off
  1930.   Example:   SET COM_HOLD=1;     (on, default is off)
  1931.   To add more than one DOS_DEVICE you need to separate with hex 0A (line-feed)
  1932.   Rexx example:
  1933.   h0A='0A'X
  1934.   setup='...;SET DOS_DEVICE=C:\OS2\MDOS\ANSI.SYS'h0A'C:\OS2\MDOS\EGA.SYS...'
  1935.  
  1936. List of DOS Setting fields
  1937. COM_HOLD
  1938. DOS_BACKGROUND_EXECUTION
  1939. DOS_BREAK
  1940. DOS_DEVICE
  1941. DOS_FCBS
  1942. DOS_FCBS_KEEP
  1943. DOS_FILES
  1944. DOS_HIGH
  1945. DOS_LASTDRIVE
  1946. DOS_RMSIZE
  1947. DOS_SHELL
  1948. DOS_STARTUP_DRIVE
  1949. DOS_UMB
  1950. DOS_VERSION
  1951. DPMI_DOS_API
  1952. DPMI_MEMORY_LIMIT
  1953. DPMI_NETWORK_BUFF_SIZE
  1954. DPMI_DOS_API
  1955. EMS_FRAME_LOCATION
  1956. EMS_HIGH_OS_MAP_REGION
  1957. EMS_LOW_OS_MAP_REGION
  1958. EMS_MEMORY_LIMIT
  1959. HW_NOSOUND
  1960. HW_ROM_TO_RAM
  1961. HW_TIMER
  1962. IDLE_SECONDS
  1963. IDLE_SENSITIVITY
  1964. KBD_ALTHOME_BYPASS
  1965. KBD_BUFFER_EXTEND
  1966. KBD_RATE_LOCK
  1967. MEM_INCLUDE_REGIONS
  1968. MEM_EXCLUDE_REGIONS
  1969. MOUSE_EXCLUSIVE_ACCESS
  1970. PRINT_TIMEOUT
  1971. VIDEO_FASTPASTE
  1972. VIDEO_MODE_RESTRICTION
  1973. VIDEO_ONDEMAND_MEMORY
  1974. VIDEO_RETRACE_EMULATION
  1975. VIDEO_ROM_EMULATION
  1976. VIDEO_SWITCH_NOTIFICATION
  1977. VIDEO_WINDOW_REFRESH
  1978. VIDEO_8514A_XGA_IOTRAP
  1979. XMS_HANDLES
  1980. XMS_MEMORY_LIMIT
  1981. XMS_MINIMUM_HMA
  1982. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  1983. <<Association>>
  1984. ASSOCFILTER  filters         Sets the filename filter for files
  1985.                              associated to this program.
  1986.                              Multiple filters are separated by commas.
  1987. ASSOCTYPE    type            Sets the type of files associated to this
  1988.                              program. Multiple filters are separated
  1989.                              by commas.
  1990. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  1991. <<Window>>
  1992. MINWIN       HIDE            Views of this object will hide when their
  1993.                              minimize button is selected.
  1994.              VIEWER          Views of this object will minimize to the
  1995.                              minimized window viewer when their minimize
  1996.                              button is selected.
  1997.              DESKTOP         Views of this object will minimize to the
  1998.                              Desktop when their minimize button is selected.
  1999. VIEWBUTTON   HIDE            Views of this object will have a hide button
  2000.                              as opposed to a minimize button.
  2001.              MINIMIZE        Views of this object will have a minimize button
  2002.                              as opposed to a hide button.
  2003. CCVIEW       YES             New views of this object will be created every
  2004.                              time the user selects open.
  2005.              NO              Open views of this object will resurface when
  2006.                              the user selects open.
  2007. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  2008. <<General>>
  2009. ICONFILE     filename        This sets the object's icon.
  2010. ICONRESOURCE id,module       This sets the object's icon. 'id' is the
  2011.                              identity of an icon resource in the 'module'
  2012.                              dynamic link library (DLL).
  2013. ICONPOS      x,y             This sets the object's initial icon position.
  2014.                              The x and y values represent the position in
  2015.                              the object's folder in percentage coordinates.
  2016. TEMPLATE     YES             Creates object as a template.
  2017.              NO              Resets objects template property.
  2018. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  2019. <<Misc>>
  2020. OBJECTID     <name>          This sets the object's identity. The object
  2021.                              id will stay with the object even if it is
  2022.                              moved or renamed. An object id is any unique
  2023.                              string preceded with a '<' and terminated
  2024.                              with a '>'. This may also be a real name
  2025.                              specified as a fully qualified path name.
  2026. HELPPANEL    id              This sets the object's default help panel.
  2027. HELPLIBRARY  filename        This sets the help library.
  2028. OPEN         SETTINGS        Open settings view when object is created.
  2029.              DEFAULT         Open default view when object is created.
  2030. NODELETE     YES             Will not allow you to delete the object.
  2031. NOCOPY       YES             Will not allow you to make a copy.
  2032. NOMOVE       YES             Will not allow you to move the object to another
  2033.                              folder, will create shadow on a move.
  2034. NODRAG       YES             Will not allow you to drag the object.
  2035. NOLINK       YES             Will not allow you to create a shadow link.
  2036. NOSHADOW     YES             Will not allow you to create a shadow link.
  2037. NORENAME     YES             Will not allow you to rename the object.
  2038. NOPRINT      YES             Will not allow you to print it.
  2039. NOTVISIBLE   YES             Will not display the object.
  2040. -----------------------------------------------------------------------------
  2041.  
  2042. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  2043. ((END TEXT INFORMATION))
  2044.  
  2045. ((BEGIN REXX CMD SAMPLES))
  2046.  
  2047. - (FOLDER.CMD)  - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  2048.  
  2049. /* FOLDER.CMD: Sample code using REXXUTIL's SysCreateObject function    */
  2050. /* Builds a folder on the DeskTop and places some program objects in it.*/
  2051. /* Mike Lamb: MIKELAMB/KGNVMC                                           */
  2052. /* Load REXXUTIL */
  2053. call rxfuncadd sysloadfuncs, rexxutil, sysloadfuncs
  2054. call sysloadfuncs
  2055.  
  2056. /*The basic call is listed next.                                           */
  2057. /*rc=SysCreateObject(classname, title, location <,setup>, <,duplicateflag>)*/
  2058.  
  2059. call SysCls
  2060. Say '';Say 'Using REXXUTILs to Add a Folder and Program Objects...'
  2061.  
  2062. Say '';Say 'Press Y to add Test Folder to Desktop...';Say '';
  2063. parse upper value SysGetKey('NOECHO') with key
  2064. If key<>'Y' Then Exit
  2065.  
  2066. /* All of the routines pass parameters to a subroutine to perform the call */
  2067. classname='WPFolder'
  2068. title='Test Folder'
  2069. location='<WP_DESKTOP>'
  2070. setup='OBJECTID=<TEST_FOLDER>'
  2071. Call BldObj
  2072.  
  2073. Say '';Say 'Now go and open up the folder, currently no items are there.'
  2074. Say 'Press ENTER and we will add a few program objects...'
  2075. key=SysGetKey()
  2076.  
  2077. Say 'Place a program object into the folder...';Say '';
  2078. classname='WPProgram'
  2079. title='SYSLEVEL-FULLSCR'
  2080. location='<TEST_FOLDER>'
  2081. setup='OBJECTID=<TEST_SYSL>;'||,
  2082.       'EXENAME=\OS2\SYSLEVEL.EXE;'||,
  2083.       'PROGTYPE=FULLSCREEN;'
  2084. Call BldObj
  2085.  
  2086. classname='WPProgram'
  2087. title='CHKDSK-PM'
  2088. location='<TEST_FOLDER>'
  2089. setup='OBJECTID=<TEST_PMCK>;'||,
  2090.       'EXENAME=\OS2\PMCHKDSK.EXE;'||,
  2091.       'MINIMIZED=YES;'||,
  2092.       'PROGTYPE=PM;'
  2093. Call BldObj
  2094.  
  2095. classname='WPProgram'
  2096. title='SYSLEVEL-VIO'
  2097. location='<TEST_FOLDER>'
  2098. setup='OBJECTID=<TEST_SYSLVIO>;'||,
  2099.       'EXENAME=\OS2\SYSLEVEL.EXE;'||,
  2100.       'PROGTYPE=WINDOWABLEVIO;'
  2101. Call BldObj
  2102.  
  2103. classname='WPProgram'
  2104. title='MEM-Fullscreen'
  2105. location='<TEST_FOLDER>'
  2106. setup='OBJECTID=<TEST_MEMFUL>;'||,
  2107.       'EXENAME=\OS2\MDOS\MEM.EXE;'||,
  2108.       'PROGTYPE=VDM;'||,
  2109.       'PARAMETERS=/?;'||,
  2110.       'NOAUTOCLOSE=YES;'
  2111. Call BldObj
  2112.  
  2113. classname='WPProgram'
  2114. title='MEM-WindowVDM'
  2115. location='<TEST_FOLDER>'
  2116. setup='OBJECTID=<TEST_MEMWIN>;'||,
  2117.       'EXENAME=\OS2\MDOS\MEM.EXE;'||,
  2118.       'PROGTYPE=WINDOWEDVDM;'||,
  2119.       'PARAMETERS=/?;'||,
  2120.       'NOAUTOCLOSE=YES;'
  2121. Call BldObj
  2122. Say '';Say 'All done, to remove objects drag to shredder...'
  2123.  
  2124. Exit
  2125.  
  2126. /* Build Object */
  2127. BldObj:
  2128. call charout ,'Building: 'title
  2129.  
  2130. /* Build object using REPLACE as duplicateflag */
  2131. result = SysCreateObject(classname, title, location, setup, 'R')
  2132.  
  2133. If result=1 Then call charout ,'...   Object created!'
  2134. Else             call charout ,'...   Not created! Return code='result
  2135.  
  2136. Say '';
  2137. Return
  2138.  
  2139. - (SHADOW.CMD)  - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  2140.  
  2141. /* SHADOW.CMD: Sample code using REXXUTIL's SysCreateObject function    */
  2142. /* Builds shadows on the DeskTop and Startup Folder                     */
  2143. /* Mike Lamb: MIKELAMB/KGNVMC                                           */
  2144. /* Load REXXUTIL */
  2145. call rxfuncadd sysloadfuncs, rexxutil, sysloadfuncs
  2146. call sysloadfuncs
  2147.  
  2148. Call SysCls
  2149. Say '';Say 'Using REXXUTILs to Add Shadow Objects...'
  2150.  
  2151. /* The titles and objectid's are found from the \OS2\INI.RC file */
  2152.  
  2153. Say '';Say 'First lets place some items on the Desktop...'
  2154. title='Enhanced Editor'; objid='<WP_EPM>'   ; loc='<WP_DESKTOP>'; call AddShad
  2155. title='OS/2 Window'    ; objid='<WP_OS2WIN>'; loc='<WP_DESKTOP>'; call AddShad
  2156. title='System Clock'   ; objid='<WP_CLOCK>' ; loc='<WP_DESKTOP>'; call AddShad
  2157.  
  2158. Say '';Say 'You can even make shadow objects of files...'
  2159. title='CONFIG.SYS'; objid='C:\CONFIG.SYS' ; loc='<WP_DESKTOP>'; call AddShad
  2160.  
  2161. Say '';Say 'Now lets place an item in the Startup Folder...'
  2162. title='System Clock'   ; objid='<WP_CLOCK>' ; loc='<WP_START>'  ; call AddShad
  2163.  
  2164. Say '';Say 'All done, to remove objects drag to shredder...'
  2165.  
  2166. Exit
  2167.  
  2168. AddShad:
  2169. Say '';Say 'Press Y to add shadow object: 'title' to 'loc
  2170. parse upper value SysGetKey('NOECHO') with key
  2171. If key='Y' Then Do
  2172.  
  2173.    /* Build object using FAIL as duplicateflag */
  2174.    result=SysCreateObject('WPShadow', title, loc, 'SHADOWID='objid, 'F')
  2175.  
  2176.    If result=1 Then Say 'Object created'
  2177.    Else             Say 'Not created, return code='result
  2178. End
  2179. Return
  2180.  
  2181. - (FLDSHAD.CMD)  - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  2182.  
  2183. /* FLDSHAD.CMD: Sample code using REXXUTIL's SysCreateObject function   */
  2184. /* Builds a folder on the DeskTop places a program object in it then    */
  2185. /* places a shadow of the program object on the DeskTop.                */
  2186. /* Mike Lamb: MIKELAMB/KGNVMC                                           */
  2187. /* Load REXXUTIL */
  2188. call rxfuncadd sysloadfuncs, rexxutil, sysloadfuncs
  2189. call sysloadfuncs
  2190.  
  2191. /*The basic call is listed next.                                           */
  2192. /*rc=SysCreateObject(classname, title, location <,setup>, <,duplicateflag>)*/
  2193.  
  2194. call SysCls
  2195. Say '';Say 'Using REXXUTILs to Add Folder/Program/Shadow Objects...'
  2196.  
  2197. Say '';Say 'Press Y to add Test Folder to Desktop...';Say '';
  2198. parse upper value SysGetKey('NOECHO') with key
  2199. If key<>'Y' Then Exit
  2200.  
  2201. classname='WPFolder'
  2202. title='Test Folder'
  2203. location='<WP_DESKTOP>'
  2204. setup='OBJECTID=<TEST2_FOLDER>'
  2205. Call BldObj
  2206.  
  2207. Say '';Say 'Press Y to place a program object into the folder...';Say '';
  2208. parse upper value SysGetKey('NOECHO') with key
  2209. If key<>'Y' Then Exit
  2210.  
  2211. classname='WPProgram'
  2212. title='SYSLEVEL-VIO'
  2213. location='<TEST2_FOLDER>'
  2214. setup='OBJECTID=<TEST2_SYSLVIO>;'||,
  2215.       'EXENAME=\OS2\SYSLEVEL.EXE;'||,
  2216.       'PROGTYPE=WINDOWABLEVIO;'
  2217. Call BldObj
  2218.  
  2219. Say '';
  2220. Say 'Press Y to place a shadow of the program object on the Desktop...';
  2221. Say '';
  2222. parse upper value SysGetKey('NOECHO') with key
  2223. If key<>'Y' Then Exit
  2224.  
  2225. classname='WPShadow'
  2226. title='SYSLEVEL-VIO'
  2227. location='<WP_DESKTOP>'
  2228. setup='SHADOWID=<TEST2_SYSLVIO>'
  2229. Call BldObj
  2230.  
  2231. Say '';Say 'All done, to remove objects drag to shredder...'
  2232.  
  2233. Exit
  2234.  
  2235. /* Build Object */
  2236. BldObj:
  2237. call charout ,'Building: 'title
  2238.  
  2239. /* Build object using REPLACE as duplicateflag */
  2240. result = SysCreateObject(classname, title, location, setup, 'R')
  2241.  
  2242. If result=1 Then call charout ,'...   Object created!'
  2243. Else             call charout ,'...   Not created! Return code='result
  2244.  
  2245. Say '';
  2246. Return
  2247.  
  2248. - (STARTDOS.CMD) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  2249.  
  2250. /* STARTDOS.CMD: Sample code using REXXUTIL's SysCreateObject function  */
  2251. /* Starts a DOS program using specific DOS VDM settings.  This is       */
  2252. /* particularly useful for LAN execution that requires NET USE commands.*/
  2253. /* The example invokes the PKZIP.EXE program using files setting of 45  */
  2254. /* Rick McGuire:  MCGUIRE/GDLVM7                                        */
  2255. /* Load REXXUTIL */
  2256. call rxfuncadd sysloadfuncs, rexxutil, sysloadfuncs
  2257. call sysloadfuncs
  2258.  
  2259. /* The basic call is listed next.                                          */
  2260. /* result = SysCreateObject(classname, title, location, setup)             */
  2261.  
  2262. classname='WPProgram'
  2263. title='My DOS Program'
  2264. location='<WP_NOWHERE>'                  /* place in invisible folder      */
  2265. program='EXENAME=C:\PKZIP.EXE;'          /* DOS program name               */
  2266. type='PROGTYPE=WINDOWEDVDM;'             /* type of DOS session (windowed) */
  2267. startup='STARTUPDIR=C:\;'                /* startup directory              */
  2268. settings='SET DOS_FILES=45;'             /* required DOS settings          */
  2269. open='OPEN=DEFAULT;'                     /* open now                       */
  2270.  
  2271. call SysCreateObject classname, title, location,,
  2272.     program||type||startup||settings||open, 'REPLACE'
  2273. Return
  2274.  
  2275. - (BOOTDOS.CMD) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  2276.  
  2277. /* BOOTDOS.CMD: Sample code using REXXUTIL's SysCreateObject function   */
  2278. /* Starts a DOS session, booting from a specific DOS image with         */
  2279. /* specific DOS VDM settings.                                           */
  2280. /* Rick McGuire:  MCGUIRE/GDLVM7                                        */
  2281. /* Load REXXUTIL */
  2282. call rxfuncadd sysloadfuncs, rexxutil, sysloadfuncs
  2283. call sysloadfuncs
  2284.  
  2285. /* The basic call is listed next.                                          */
  2286. /* result = SysCreateObject(classname, title, location, setup)             */
  2287.  
  2288. classname='WPProgram'
  2289. title='Booted DR DOS'
  2290. location='<WP_NOWHERE>'                  /* place in invisible folder      */
  2291. program='EXENAME=*;'                     /* DOS program name (use shell)   */
  2292. type='PROGTYPE=WINDOWEDVDM;'             /* type of DOS session (windowed) */
  2293. image='C:\DRDOS.VM;'                     /* DOS image file                 */
  2294.                                          /* required DOS settings          */
  2295. settings='SET DOS_BACKGROUND_EXECUTION=ON;'
  2296. open='OPEN=DEFAULT;'                     /* open now                       */
  2297.  
  2298. call SysCreateObject classname, title, location,,
  2299.     program||type||image||settings||open, 'REPLACE'
  2300. Return
  2301.  
  2302. - (REBUILD.CMD) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  2303.  
  2304. /* REBUILD.CMD: Sample code using REXXUTIL's SysCreateObject function   */
  2305. /* Can be used to rebuild objects created during the installation of    */
  2306. /* your OS/2 system. The \OS2\INSTALL\INI.RC file contains information  */
  2307. /* that can be used by the SysCreateObject function.                    */
  2308. /* The INI.RC file is used by MAKEINI.EXE to create your OS2.INI file   */
  2309. /* Syntax:  Enter  "REBUILD ?" for complete syntax                      */
  2310. /* Mike Lamb: MIKELAMB/KGNVMC                                           */
  2311. '@ECHO OFF'
  2312. /* Load REXXUTIL */
  2313. call rxfuncadd sysloadfuncs, rexxutil, sysloadfuncs
  2314. call sysloadfuncs
  2315.  
  2316. Arg parms
  2317. cmdparms=parms /* Save command line parms for later processing */
  2318.  
  2319. /* Until REXXUTIL offers a function call to retrieve the OS2 boot drive   */
  2320. /* we assume the environment variable COMSPEC has location of boot drive. */
  2321. BtDrv=filespec('drive',value('COMSPEC',,'OS2ENVIRONMENT'))
  2322.  
  2323. parse upper var cmdparms type '(' inifile .
  2324. /* If user does not enter location of *.RC file then try to find it */
  2325. If inifile='' Then inifile=BtDrv||'\OS2\INI.RC'
  2326. rcx=stream(inifile,'C','Q EXISTS')
  2327. If rcx='' Then Do
  2328.    Say '';Say '';Say inifile 'not found'
  2329.    Return
  2330. End
  2331. type=left(type,1)
  2332. If verify(type,'FPOA') Then Signal Helper
  2333.  
  2334. /* Initialize tables and table counters */
  2335. iniftab.=''; iniptab.='' iniotab.=''; /*Folders, Programs, Others */
  2336. iniflns=0;   iniplns=0;  iniolns=0;
  2337. initab.='';  inilns=0;
  2338. Call stream inifile,'C','CLOSE'
  2339. Do while lines(inifile)>0  /* Read RC file into tables */
  2340.    lne=linein(inifile)
  2341.    parse var lne '"PM_InstallObject"' lne
  2342.    If lne\='' Then Do
  2343.       parse var lne '"'rest1'" 'lne
  2344.       parse var lne '"'setup'"'
  2345.       parse var rest1 title';'object';'location
  2346.       If object='WPFolder' Then Do
  2347.          iniflns=iniflns+1
  2348.          iniftab.1.iniflns=object;   iniftab.2.iniflns=title;
  2349.          iniftab.3.iniflns=location; iniftab.4.iniflns=setup;
  2350.       End
  2351.       Else If object='WPProgram' Then Do
  2352.          iniplns=iniplns+1
  2353.          iniptab.1.iniplns=object;   iniptab.2.iniplns=title;
  2354.          iniptab.3.iniplns=location; iniptab.4.iniplns=setup;
  2355.       End
  2356.       Else Do
  2357.          iniolns=iniolns+1
  2358.          iniotab.1.iniolns=object;   iniotab.2.iniolns=title;
  2359.          iniotab.3.iniolns=location; iniotab.4.iniolns=setup;
  2360.       End
  2361.    End
  2362. End
  2363. Call stream inifile,'C','CLOSE'
  2364.  
  2365. /* Calculation for screen loop */
  2366. parse value SysTextScreenSize() with row col
  2367. scrsz=row-12
  2368.  
  2369. If type='F' | type='A' Then Do; /* Folder routine */
  2370.    objt='Folder'; inilns=iniflns;
  2371.    Do i=1 to inilns; Do j=1 to 4;
  2372.       initab.j.i=iniftab.j.i
  2373.    End; End;
  2374.    Call DispSel
  2375. End;
  2376. If type='P' | type='A' Then Do; /* Program routine */
  2377.    objt='Program'; inilns=iniplns;
  2378.    Do i=1 to inilns; Do j=1 to 4;
  2379.       initab.j.i=iniptab.j.i
  2380.    End; End;
  2381.    Call DispSel
  2382. End;
  2383. If type='O' | type='A' Then Do; /* Other routine */
  2384.    objt='Other'; inilns=iniolns;
  2385.    Do i=1 to inilns; Do j=1 to 4;
  2386.       initab.j.i=iniotab.j.i
  2387.    End; End;
  2388.    Call DispSel
  2389. End;
  2390. Return; /* When get here done with processing */
  2391.  
  2392. /* Routine to display objects and allow selection */
  2393. DispSel:
  2394. key=''
  2395. Do while key\='Q'
  2396.    Call SysCls; Say '';Say objt' objects found in: 'inifile;Say '';
  2397.    Do i=1 to inilns
  2398.       If trunc(i/scrsz)==i/scrsz Then Call Promptx 1
  2399.       If key='Q' Then leave
  2400.       n=right('  '||i,3)||') '||left(initab.2.i||copies(' ',30),30)
  2401.       n=n||left(initab.3.i||copies(' ',20),20)
  2402.       Say n
  2403.    End
  2404.    If key\='Q' Then Call Promptx 0
  2405. End
  2406. Return
  2407.  
  2408. /* Screen loop routine also calls object build routine */
  2409. Promptx: Arg scr
  2410. Say '';Say 'To attempt to rebuild an object enter the number of the object'
  2411. If scr=0 Then Say 'or enter Q to quit...'
  2412. Else Say 'or press enter to show next screen...  Or enter Q to Quit...'
  2413. pull key .
  2414. If (key>=1) & (key <=inilns) then,
  2415.     rcx=BldIt(initab.1.key,initab.2.key,initab.3.key,initab.4.key)
  2416. If scr=1 Then Do;
  2417.    Call SysCls;Say '';Say objt' objects found in: 'inifile;Say '';
  2418. End;
  2419. Return
  2420.  
  2421. /* Routine to build object */
  2422. BldIt: Parse Arg object,title,location,setup
  2423. If object='WPFolder' Then Do
  2424.    call SysCls
  2425.    Say '';Say '';
  2426.    Say 'WARNING: Any attempt to rebuild a folder object will first'
  2427.    Say '         delete each and every object in that folder!!!!'
  2428.    Say ''
  2429.    Say 'If you really do want to rebuild: 'title
  2430.    Say 'Press Y, any other key will not rebuild.'
  2431.    parse upper value SysGetKey('NOECHO') with key
  2432.    If key<>'Y' Then Return ''
  2433. End
  2434. Say 'SysCreateObject('object', 'title', 'location', 'setup', R)'
  2435. /* Build object using REPLACE as duplicateflag */
  2436. result = SysCreateObject(object, title, location, setup, 'R')
  2437. If result=1 Then Say '...   Object created!'
  2438. Else             Say '...   Not created! Return code='result
  2439. Say '';Say 'Press ENTER to continue...'
  2440. Pull ans
  2441. Return result
  2442.  
  2443. /* Syntax help */
  2444. Helper:
  2445. call SysCls
  2446. Say '';Say ''; Say 'REBUILD:'
  2447. Say 'Routine to rebuild system installed objects listed in *.RC files.'
  2448. Say 'Can be used as an alternative to using the MAKEINI command.'
  2449. Say 'Your INI.RC file is used by MAKEINI.EXE during installation to'
  2450. Say 'create your OS2.INI file.'
  2451. Say '';
  2452. Say 'Any attempt to rebuild an object first deletes any object that'
  2453. Say 'is using that same <objectid>. This can be useful if you want to'
  2454. Say 'restore an object back to its original installed state. This can'
  2455. Say 'also be bad since if you rebuild a folder it first deletes all'
  2456. Say 'objects in it since that is its initial install state.'
  2457. Say ''; Say 'Syntax:';Say '';
  2458. Say 'REBUILD object [(filespec]'
  2459. Say '';Say 'Valid objects A(ll), F(olders), P(rograms), O(ther)'
  2460. Say 'Can also can use (filespec for name of *.RC file, default is \OS2\INI.RC'
  2461. Exit
  2462.  
  2463. - (LPTADD.CMD) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  2464.  
  2465. /* LPTADD.CMD: Sample code using REXXUTIL's SysIni function.            */
  2466. /* Routine will expand the number of LPT ports the WorkPlace Shell      */
  2467. /* recognizes from LPT1-3 to LPT1-9. Also a routine to add LPT3-9 to    */
  2468. /* the WIN-OS2 WIN.INI file.                                            */
  2469. /* Mike Lamb: MIKELAMB/KGNVMC                                           */
  2470. '@ECHO OFF'
  2471. /* Load REXXUTIL */
  2472. call rxfuncadd sysloadfuncs, rexxutil, sysloadfuncs
  2473. call sysloadfuncs
  2474.  
  2475. /* The basic call for setting a single key value is listed next.        */
  2476. /* result = SysIni([inifile], app, key, val)                            */
  2477.  
  2478. call SysCls; Say '';
  2479. Say 'Using REXXUTILs SysIni call to add LPT4-9 to the WorkPlace Shell'
  2480. Say '';Say 'Press Y to add/initialize LPT4-9 ports...';Say '';
  2481. parse upper value SysGetKey('NOECHO') with key
  2482. If key='Y' Then Do
  2483.    Say 'LPT Ports: setting up for LPT4-9 ports...'
  2484.    Do n=4 to 9
  2485.       Say ' Setting up PM_LPT'n'...'
  2486.       rx=SysIni('SYSTEM', 'PM_SPOOLER_PORT', 'LPT'n, ';'||'00'x)
  2487.       If rx\='' Then Say 'LPT'n' Bad result='result
  2488.       rx=SysIni('SYSTEM', 'PM_LPT'n,         'DESCRIPTION', 'LPT'||n||'00'x)
  2489.       If rx\='' Then Say 'LPT'n' Bad result='result
  2490.       rx=SysIni('SYSTEM', 'PM_LPT'n,         'INITIALIZATION', ';'||'00'x)
  2491.       If rx\='' Then Say 'LPT'n' Bad result='result
  2492.       rx=SysIni('SYSTEM', 'PM_LPT'n,         'PORTDRIVER', 'PARALLEL;'||'00'x)
  2493.       If rx\='' Then Say 'LPT'n' Bad result='result
  2494.       rx=SysIni('SYSTEM', 'PM_LPT'n,         'TERMINATION', ';'||'00'x)
  2495.       If rx\='' Then Say 'LPT'n' Bad result='result
  2496.       rx=SysIni('SYSTEM', 'PM_LPT'n,         'TIMEOUT', '45;'||'00'x)
  2497.       If rx\='' Then Say 'LPT'n' Bad result='result
  2498.    End
  2499.    Say 'LPT4-9 added... Press any key to continue...'
  2500.    SysGetKey('NOECHO')
  2501. End
  2502.  
  2503. call SysCls; Say '';
  2504. Say 'Can now attempt to add LPT3-9 to your WIN-OS2 WIN.INI file.'
  2505. Say '';Say 'Press Y to attempt to add LPT3-9 ports to WIN-OS2...';Say '';
  2506. parse upper value SysGetKey('NOECHO') with key
  2507. If key='Y' Then Do
  2508.   /* Change \OS2\MDOS\WINOS2\WIN.INI to add more ports LPT3-LPT9 */
  2509.   win.='';winnew.='';
  2510.   /* Until REXXUTIL offers a function call to retrieve the OS2 boot drive  */
  2511.   /* we assume the enviroment variable COMSPEC has location of boot drive. */
  2512.   BtDrv=filespec('drive',value('COMSPEC',,'OS2ENVIRONMENT'))
  2513.   fn=BtDrv'\OS2\MDOS\WINOS2\WIN.INI';
  2514.   fnx=stream(fn,'C','QUERY EXISTS')
  2515.   fn=fnx;
  2516.   If fn\='' Then Do /* If file exists then process adding extra ports */
  2517.      Call stream fn,'C','CLOSE'
  2518.      Do i=1 to 10000 while LINES(fn)>0
  2519.         parse value linein(fn) with win.i
  2520.      End
  2521.      Call stream fn,'C','CLOSE'
  2522.      i=i-1; k=0;
  2523.      Do j=1 to i /* Look for FILE:= then if line before = LPT2.OS2= add 3-9 */
  2524.         If win.j='FILE:=' Then Do
  2525.            m=j-1; winchg=no;
  2526.            If win.m='LPT2.OS2=' Then Do
  2527.               Say 'LPT Ports: setting up for Windows LPT3-9 ports...'
  2528.               winchg=yes;
  2529.               Do n=3 to 9
  2530.                  Say ' Setting up: LPT'n'.OS2='
  2531.                  k=k+1; winnew.k='LPT'n'.OS2='
  2532.               End;
  2533.            End;
  2534.         End;
  2535.         k=k+1;
  2536.         winnew.k=win.j;
  2537.      End;
  2538.      If winchg=yes Then Do;
  2539.         parse var fnx fnx'.' .
  2540.         ifn=fnx||'.???';
  2541.         ifn=SysTempFileName(ifn)
  2542.         '@COPY' fn ifn '1>NUL 2>NUL' /* Copy original to backup name */
  2543.         Say 'Copy of' fn 'saved as' ifn
  2544.         Say 'Writing' fn 'with added lines.'
  2545.         call lineout fn,,1 /* Start writing at first character */
  2546.         Do i=1 to k /* write file back out */
  2547.            call lineout fn,winnew.i
  2548.         End
  2549.         Call stream fn,'C','CLOSE'
  2550.      End;
  2551.      Else Say 'Lines not added, either already done or not what we expect.'
  2552.   End;
  2553.   Else Say 'Could not locate' fn 'program ending...'
  2554. End;
  2555. Say 'LPTADD ending...'
  2556. Exit
  2557.  
  2558. - (OBJECTID.CMD) - - --  - - - - - - - - - - - - - - - - - - - - - - - - - -
  2559.  
  2560. /* OBJECTID.CMD: Sample code using REXXUTIL's SysIni function.          */
  2561. /* Routine will display the OBJECTIDs known to the WorkPlace Shell      */
  2562. /* Mike Lamb: MIKELAMB/KGNVMC                                           */
  2563. '@ECHO OFF'
  2564. /* Load REXXUTIL */
  2565. call rxfuncadd sysloadfuncs, rexxutil, sysloadfuncs
  2566. call sysloadfuncs
  2567.  
  2568. /* List ObjectIds */
  2569. App='PM_Workplace:Location'
  2570. call SysIni 'USER', App, 'All:', 'Keys'
  2571. if Result \= 'ERROR:' then do
  2572.    Call SysCls
  2573.    Say '';Say '';Say 'Listing ObjectId information';Say '';
  2574.    parse value SysTextScreenSize() with row col
  2575.    j=row-10
  2576.    Do i=1 to Keys.0
  2577.       If trunc(i/j)==i/j Then Do
  2578.          Say '';Say 'Press any key to show next screen...'
  2579.          key=SysGetKey()
  2580.          Call SysCls
  2581.          Say '';Say '';Say 'Listing ObjectId information';Say '';
  2582.       End
  2583.       Say Keys.i
  2584.    End
  2585. End
  2586. Else Say 'Error querying for' App
  2587. Return
  2588.  
  2589. - (FONTS.CMD) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  2590.  
  2591. /* FONTS.CMD: Sample code using REXXUTIL's SysIni function.             */
  2592. /* Routine will display the FONTS known to the WorkPlace Shell          */
  2593. /* Mike Lamb: MIKELAMB/KGNVMC                                           */
  2594. '@ECHO OFF'
  2595. /* Load REXXUTIL */
  2596. call rxfuncadd sysloadfuncs, rexxutil, sysloadfuncs
  2597. call sysloadfuncs
  2598.  
  2599. /* List installed Fonts */
  2600. App='PM_Fonts'
  2601. call SysIni 'USER', App, 'All:', 'Keys'
  2602. If Result \= 'ERROR:' then do
  2603.    Do j=1 to Keys.0
  2604.       Keys.j=Keys.j 'Installed as:' SysIni('USER', App, Keys.j)
  2605.    End
  2606.    Call SysCls
  2607.    Say '';Say '';Say 'Listing Installed Fonts';Say '';
  2608.    parse value SysTextScreenSize() with row col
  2609.    j=row-10
  2610.    Do i=1 to Keys.0
  2611.       If trunc(i/j)==i/j Then Do
  2612.          Say '';Say 'Press any key to show next screen...'
  2613.          key=SysGetKey()
  2614.          Call SysCls
  2615.          Say '';Say '';Say 'Listing Installed Fonts';Say '';
  2616.       End
  2617.       Say Keys.i
  2618.    End
  2619. End
  2620. Else Say 'Error querying for' App
  2621. Return
  2622.  
  2623. - (ICONRES.CMD) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  2624.  
  2625. /* ICONRES.CMD: Sample code using REXXUTIL's SysCreateObject function   */
  2626. /* Routine will create a folder containing many icons available in      */
  2627. /* installed DLLs on an OS/2 V2 system. Shows how to use the setup      */
  2628. /* string parm: ICONRESOURCE                                            */
  2629. /* Mike Lamb: MIKELAMB/KGNVMC                                           */
  2630. '@ECHO OFF'
  2631. /* Load REXXUTIL */
  2632. call rxfuncadd sysloadfuncs, rexxutil, sysloadfuncs
  2633. call sysloadfuncs
  2634.  
  2635. call SysCls
  2636. Say '';
  2637. Say 'Using REXXUTILs to demonstrate use of the ICONRESOURCE parameter.'
  2638. Say 'A folder will be created and populated with various icons found'
  2639. Say 'in some installed DLL files.'
  2640. Say '';
  2641. Say 'ICONRESOURCE is a SysCreateObject setup string parameter, has syntax:'
  2642. Say '';
  2643. Say '  ICONRESOURCE=id module       Ex:  ICONRESOURCE=3 PMWP;'
  2644. Say '  id=number of the icon resource, module=filename of the DLL'
  2645. Say ''; Say 'NOTE: Over 70 icons, program will run for a minute or two.'
  2646. Say '      After program ends the WPS will continue to resolve objects, also'
  2647. Say '      the building of the objects adds approx 100K to your OS2.INI.'
  2648. Say '';Say 'Press Y to add the folder to Desktop and populate...';Say '';
  2649. parse upper value SysGetKey('NOECHO') with key
  2650. If key<>'Y' Then Exit
  2651.  
  2652. /* Build folder for icons */
  2653. call charout ,'Building: ICONRESOURCE Icon Folder'
  2654. result = SysCreateObject('WPFolder', 'ICONRESOURCE^Icon Folder',,
  2655.         '<WP_DESKTOP>', 'OBJECTID=<ICN_FOLDER>;', 'R')
  2656. If result=1 Then call charout ,'...   Object created!'
  2657. Else             call charout ,'...   Not created! Return code='result
  2658. Say '';
  2659. classname='WPAbstract'
  2660. location='<ICN_FOLDER>'
  2661. /* WPCONFIG 1-13 WPPRTMRI 3-16 19-23 */
  2662. fn='PMWP'
  2663. Do i=1 to 75
  2664.    If i<5 | i=13 | (i>15 & i<21) | i=22 | (i>23 & i<30) | i=32 | i=33,
  2665.     | i=44 | i=46 | i=48 | i=52 | i=53 | (i>55 & i<73) Then Call BldObj
  2666. End
  2667. fn='WPCONFIG'
  2668. Do i=1 to 13
  2669.    Call BldObj
  2670. End
  2671. fn='WPPRTMRI'
  2672. Do i=3 to 23
  2673.    If (i<17 | i>18) Then Call BldObj
  2674. End
  2675. Say '';Say 'All done, to remove drag folder to shredder...'
  2676. Exit
  2677.  
  2678. /* Build Object */
  2679. BldObj:
  2680. if i<10 then j='0'||i
  2681. else j=i
  2682. title=fn'-'||j
  2683. setup='ICONRESOURCE='||j||' 'fn';OBJECTID=<ICN-'fn'-'||j||'>'
  2684. call charout ,'Building: 'title
  2685. result = SysCreateObject(classname, title, location, setup, 'R')
  2686. If result=1 Then call charout ,'...   Object created!'
  2687. Else             call charout ,'...   Not created! Return code='result
  2688. Say '';
  2689. Return
  2690.  
  2691. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  2692. ((END REXX CMD SAMPLES))
  2693.  
  2694. ((BEGIN CODE FRAGMENTS))
  2695. - (SYSSET)  - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  2696.  
  2697. System Settings
  2698. ===============
  2699. During our attempts at customizing the shell using REXXUTILs for newly created
  2700. workstations we discovered many items can be controlled. Our first attempt was
  2701. to turn off the default setting for Workplace Shell Print Screen. We wanted it
  2702. disabled instead of enabled (saves our customers from accidentally printing
  2703. the workplace shell screen contents :-)
  2704. From there we learned other items could be changed:
  2705.  
  2706. Remember the basic SysIni call is:
  2707.   result = SysIni([inifile], app, key, val)
  2708.  
  2709. Note: Some items if changed did not seem to take effect until the next reboot.
  2710.  
  2711. To see the menu items that can be changed go to:
  2712.  OS/2 System / System Setup / System, Window tab
  2713.  
  2714. Button appearance for windows
  2715. -----------------------------
  2716. /* Hide button = 1 plus hex 0 */
  2717. result = SysIni('USER', 'PM_ControlPanel', 'MinButtonType', '1'||'00'x)
  2718. /* Minimize button = 2 plus hex 0 */
  2719. result = SysIni('USER', 'PM_ControlPanel', 'MinButtonType', '2'||'00'x)
  2720.  
  2721. Animation
  2722. ---------
  2723. /* Enabled = hex 01 00 00 00 */
  2724. result = SysIni('USER', 'PM_ControlPanel', 'Animation', '01000000'x)
  2725. /* Disabled = hex 00 00 00 00 */
  2726. result = SysIni('USER', 'PM_ControlPanel', 'Animation', '00000000'x)
  2727.  
  2728. Minimize button behavior
  2729. ------------------------
  2730. /* Hide Window = 1 plus hex 0 */
  2731. result = SysIni('USER', 'PM_ControlPanel', 'HiddenMinWindows', '1'||'00'x)
  2732. /* Minimize window to viewer = 2 plus hex 0 */
  2733. result = SysIni('USER', 'PM_ControlPanel', 'HiddenMinWindows', '2'||'00'x)
  2734. /* Minimize window to desktop = 3 plus hex 0 */
  2735. result = SysIni('USER', 'PM_ControlPanel', 'HiddenMinWindows', '3'||'00'x)
  2736.  
  2737. Object Open Behavior
  2738. --------------------
  2739. /* Display existing window; delete CCVIEW key */
  2740. result = SysIni('USER', 'PM_Workplace', 'CCVIEW', 'DELETE:')
  2741. /* Create new window; CCVIEW key set to 'ON' */
  2742. result = SysIni('USER', 'PM_Workplace', 'CCVIEW', 'ON'||'00'x)
  2743.  
  2744. To see the menu items that can be changed go to:
  2745.  OS/2 System / System Setup / System, Print Screen tab
  2746.  
  2747. Print Screen
  2748. ------------
  2749. /* Disable print screen */
  2750. result = SysIni('USER', 'PM_ControlPanel', 'PrintScreen', '0'||'00'x)
  2751. /* Enable print screen */
  2752. result = SysIni('USER', 'PM_ControlPanel', 'PrintScreen', '1'||'00'x)
  2753.  
  2754. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  2755. ((END CODE FRAGMENTS))
  2756.  
  2757. END: REXXUTIL Information and Samples
  2758.  
  2759.               Michael A. Lamb  (MIKELAMB @ KGNVMC)  1992/07/29 10:05 EDT
  2760.  
  2761. ----- OS2REXX CFORUM appended at 13:07:18 on 92/06/19 GMT (by CONT00 at LEXVMK)
  2762. Subject: Rexx not freeing DLL for external function
  2763. Ref:     Append at 02:37:28 on 92/06/19 GMT (by SDETWEIL at DETVMIC4)
  2764.  
  2765. Oh... I see, thanks !
  2766.  
  2767. Gregory Czaja, Lexington 8-545-3311  1992/06/19  09:06
  2768.  
  2769. ----- OS2REXX CFORUM appended at 22:13:35 on 92/06/19 GMT (by MAGUIRET at RHQVM21)
  2770. Subject: SHVBLOCK Question
  2771. Ref:     none
  2772.  
  2773. What value do I use to signify the end of chain for shvnext?
  2774. NULL?
  2775.  
  2776. Tom Maguire
  2777.  
  2778. ----- OS2REXX CFORUM appended at 15:24:53 on 92/06/22 GMT (by MAGUIRET at RHQVM21)
  2779. Subject: External Function Debugging Tips?
  2780. Ref:     none
  2781.  
  2782. Anybody have any tips on how to debug an external function in a DLL?
  2783.  
  2784. Tom Maguire
  2785.  
  2786. ----- OS2REXX CFORUM appended at 19:52:42 on 92/06/22 GMT (by PMUELLR at CARVM3)
  2787. Subject: External Function Debugging Tips?
  2788. Ref:     Append at 15:24:53 on 92/06/22 GMT (by MAGUIRET at RHQVM21)
  2789.  
  2790. The trick is to run an .exe which ends up running a .cmd file that
  2791. uses the function.  I've never tried this, but you may be able to
  2792. get it to work with PMREXX.  Start PMREXX under IPMD, set the
  2793. load dll breakpoint, and you might be able to get into your DLL this
  2794. way.  You will probably need to 'unload' the DLL before you do this
  2795. (each time! before you do this).
  2796.  
  2797. Another way is to write a C program that does a RexxStart on a given
  2798. .cmd file, but also does a DosLoadModule() on the DLL you want to
  2799. debug.
  2800.  
  2801. Patrick Mueller - IBM Cary
  2802.  
  2803. ----- OS2REXX CFORUM appended at 13:57:49 on 92/06/23 GMT (by MAAV7IB at OS2CUST)
  2804. Subject: Querying Extended Attributes
  2805.  
  2806. Is there a REXX Utility Function which will return the names of the extended
  2807. attributes that a file has?  I would like to retrieve the extended attribute
  2808. values with SysGetEA, but I need to get the names of these values first.
  2809.  
  2810. Also, is there a REXX function to delete an extended attribute?  Or can
  2811. SysPutEA do it (with a null value)?
  2812.  
  2813. Kevin Miller
  2814.  
  2815. ----- OS2REXX CFORUM appended at 13:24:22 on 92/06/24 GMT (by PASPUNG at CARVM3)
  2816. Subject: External Function Debugging Tips?
  2817. Ref:     Append at 15:24:53 on 92/06/22 GMT (by MAGUIRET at RHQVM21)
  2818.  
  2819. Another way is to write some stub code that simulates a call to your function.
  2820. Then link the function in with the stub code, instead of using a DLL.
  2821. This way you can use your normal debugging tools (eg, CodeView) to get
  2822. the function 99% there.  Then re-link the function as a DLL, and call it
  2823. using some Rexx test programs to get the remaining 1% tested/completed.
  2824.  
  2825. Peter A. Spung, IBM Application Platform Products MDQ Chair, Cary, NC (TEAMOS2)
  2826.  
  2827. ----- OS2REXX CFORUM appended at 14:42:56 on 92/06/24 GMT (by SAMI3QU at OS2CUST)
  2828. Subject: SHVBLOCK Question
  2829. Ref: Append at 22:13:35 on 92/06/19 GMT (by MAGUIRET at RHQVM21)
  2830.  
  2831. The SHVBLOCK chain is terminated with low values in SHVNEXT.
  2832.  
  2833. Mark Thompson - Coal Services Corp., St. Louis, MO
  2834.  
  2835. ----- OS2REXX CFORUM appended at 01:25:08 on 92/06/25 GMT (by SDETWEIL at DETVMIC4)
  2836. Subject: External Function Debugging Tips?
  2837. Ref:     Append at 15:24:53 on 92/06/22 GMT (by MAGUIRET at RHQVM21)
  2838.  
  2839. Using Codeview or IPMD
  2840.  
  2841. Codeview CMD.EXE /C somerexx.cmd /L dllname
  2842.  
  2843. Sam
  2844.  
  2845. ----- OS2REXX CFORUM appended at 21:44:02 on 92/06/26 GMT (by MCCS001 at OS2CUST)
  2846. Subject: REXX documentation
  2847. Ref: Append at 17:48:17 on 92/06/25 GMT (by MCCS001 at OS2CUST)
  2848.  
  2849. OS/2 Procedures Language 2/REXX Reference is S10G-6268;  User's Guide is
  2850. S10G-6269.
  2851.  
  2852. Campbell Nelson (UCLA Med Cntr Comp Svcs)
  2853.  
  2854. ----- OS2REXX CFORUM appended at 16:26:37 on 92/06/30 GMT (by 64932769 at TOROHON1)
  2855. Subject: Executing a C program from a DEATCHED REXX Program
  2856. Ref:     Append at 01:25:08 on 92/06/25 GMT (by SDETWEIL at DETVMIC4)
  2857.  
  2858. I have a REXX question and I hope someone can help me answer it or   m
  2859. provide me with a name to contact.
  2860.  
  2861. The problem/question is this:
  2862.  
  2863. I have an EZVU panel which DETACHES a REXX program.  This REXX program
  2864. in turn, executes a C program called NOTIFY.  The NOTIFY program then
  2865. pops up a message to the user using VIOPOPUP.  This scenario works
  2866. fine in OS/2 1.3.
  2867.  
  2868. However, in OS/2 2.0, the NOTIFY.EXE program cannot be started.
  2869. If I "DETACH" the NOTIFY program it works.  It seems the REXX
  2870. environment is preventing another program from starting up unless it
  2871. is detached.  I am trying to understand if this is the reason.
  2872. In picture format:
  2873.  
  2874.   EZVU Panel ----------> REXX.CMD ----------> NOTIFY.EXE
  2875.                 DETACHES           executes
  2876.  
  2877.   - This works under OS/2 1.3
  2878.   - Under OS/2 2.0,  The NOTIFY program is not startable.
  2879.     However, if I "DETACH" NOTIFY.EXE, it works.
  2880.  
  2881. I know it is not the EZVU panel because I can simulate the above problem
  2882. from an OS/2 commadn line.
  2883.  
  2884. Any GURUs with an answer or explaination.......
  2885. Stanton (SAUYONG at TOROVM1)
  2886.  
  2887. ----- OS2REXX CFORUM appended at 18:16:38 on 92/06/30 GMT (by SDETWEIL at DETVMIC4)
  2888. Subject: Executing a C program from a DEATCHED REXX Program
  2889. Ref:     Append at 16:26:37 on 92/06/30 GMT (by 64932769 at TOROHON1)
  2890.  
  2891. I have a coupleof execs like this too without problem under 2.0
  2892.  
  2893. First test I would add TRACE i to the Rexx exec
  2894.  
  2895. then DETACH  rexx.CMD >somefile 2>&1
  2896.  
  2897. When the exec ends look at the trace to see what may have caused
  2898. the problem.
  2899.  
  2900. Sam
  2901.  
  2902. ----- OS2REXX CFORUM appended at 14:34:22 on 92/07/01 GMT (by SAMI3QU at OS2CUST)
  2903. Subject: Modifying/opening objects with SysCreateObject
  2904.  
  2905. I have read in various appends that SysCreateObject can be used to modify
  2906. and open existing WPS objects.  I have not been able to do this (the function
  2907. simply returns 0).  Would someone please post an example?  Thanks.
  2908.  
  2909. Mark Thompson - Coal Services Corp.  St. Louis, MO
  2910.  
  2911. ----- OS2REXX CFORUM appended at 15:29:31 on 92/07/01 GMT (by SAMI3QU at OS2CUST)
  2912. Subject: ABORTRETRYCANCEL button-type in RxMessageBox
  2913.  
  2914. If I call RxMessageBox and specify a button-type of ABORTRETRYCANCEL, I get
  2915. a "incorrect call to routine" error.  If I change to a RETRYCANCEL button, it
  2916. works fine.  Has anyone else had this problem?
  2917.  
  2918. Mark Thompson - Coal Services Corp.  St. Louis, MO
  2919.  
  2920. ----- OS2REXX CFORUM appended at 13:27:36 on 92/07/02 GMT (by SHABBY at RCHVMP)
  2921. Subject: ABORTRETRYCANCEL button-type in RxMessageBox
  2922. Ref:     Append at 15:29:31 on 92/07/01 GMT (by SAMI3QU at OS2CUST)
  2923.  
  2924. Isn't that supposed to be ABORTRETRYIGNORE ?  I'm not sure, but that's
  2925. what is in WinMessageBox...
  2926.  
  2927. -Chris
  2928.  
  2929. ----- OS2REXX CFORUM appended at 16:22:49 on 92/07/02 GMT (by CONT00 at LEXVMK)
  2930. ..... OS2REXX CFORUM modified at 15:45:37 on 92/08/24 GMT (by CONT00 at LEXVMK)
  2931. Subject: Modifying/opening objects with SysCreateObject
  2932. Ref:     Append at 14:34:22 on 92/07/01 GMT (by SAMI3QU at OS2CUST)
  2933.  
  2934. not documented, not supported, not allowed...
  2935.  
  2936. Gregory Czaja, Lexington 8-545-3311  1992/07/02  12:20
  2937.  
  2938. ----- OS2REXX CFORUM appended at 17:16:48 on 92/07/02 GMT (by 64932769 at TOROHON1)
  2939. Subject: Executing a C program from a DEATCHED REXX Program
  2940. Ref:     Append at 18:16:38 on 92/06/30 GMT (by SDETWEIL at DETVMIC4)
  2941.  
  2942. Sam,
  2943. thanks for your suggestion.  I did try putting a 'trace' and all I got
  2944. was a SYS1059.  The explaination was not very helpfull.  The fact that
  2945. the REXX program and "c" program works under OS/2 1.3 but now fails
  2946. under OS/2 2.0 implies something has changed but where....
  2947. I am still open for suggestions....
  2948.  
  2949. Stanton (SAUYONG at TOROVM1)
  2950.  
  2951. ----- OS2REXX CFORUM appended at 19:08:51 on 92/07/03 GMT (by NBLKCY0 at OS2CUST)
  2952. Subject: ADDRESS CPIC - Samples?
  2953.  
  2954. I understand that REXX can support LU6.2 communications through the
  2955. ADDRESS CPIC command.  Can anyone provide a sample of this code?
  2956.  
  2957. Where can I find documentation on the CPIC implementation in REXX?
  2958.  
  2959. John Wilson - Citizens Fidelity Bank
  2960.  
  2961. ----- OS2REXX CFORUM appended at 14:55:04 on 92/07/06 GMT (by GARRISON at AUSVM1)
  2962. Subject: ADDRESS CPIC - Samples?
  2963. Ref:     Append at 19:08:51 on 92/07/03 GMT (by NBLKCY0 at OS2CUST)
  2964.  
  2965. John,
  2966. I'm aware of a couple of sources of info that might be useful to you:
  2967.  
  2968. APPC & CPI-C Brief (GG24-3520)
  2969. Extended Services CM Sample Program Diskette (S04G-1031)
  2970.  
  2971. The CM Sample Program Diskette contains a pair of REXX CPI-C programs,
  2972. plus a lot more (APPC, System Management, EHLLAPI, ACDI, LUA, SRPI,
  2973. Netbios, 802.2, CMStop, etc.).
  2974.  
  2975. There is a CPI-C manual that provides information for the various
  2976. supported languages (C, COBOL, FORTRAN, REXX, etc.), but I haven't been
  2977. able to run down the order number.  Perhaps someone else can help?
  2978.  
  2979. Mike Garrison
  2980.  
  2981. ----- OS2REXX CFORUM appended at 20:32:50 on 92/07/06 GMT (by SAMI3QU at OS2CUST)
  2982. Subject: ABORTRETRYCANCEL button-type in RxMessageBox
  2983. Ref: Append at 13:27:36 on 92/07/02 GMT (by SHABBY at RCHVMP)
  2984.  
  2985. You're absolutely right, Chris!  The online REXX documentation is incorrect.
  2986. I changed my exec to ABORTRETRYIGNORE and it works great!  Thanks.
  2987.  
  2988. Mark Thompson - Coal Services Corp.  St. Louis, MO
  2989.  
  2990. ----- OS2REXX CFORUM appended at 20:36:25 on 92/07/06 GMT (by SAMI3QU at OS2CUST)
  2991. Subject: Modifying/opening objects with SysCreateObject
  2992. Ref: Append at 16:22:49 on 92/07/02 GMT (by CONT00 at LEXVMK)
  2993.  
  2994. Thanks for the example, Gregory.  I had somehow convinced myself that the
  2995. original object could be opened directly, thus my lack of success.  Creating
  2996. a Shadow works like charm.
  2997.  
  2998. Mark Thompson - Coal Services Corp.  St. Louis, MO
  2999.  
  3000. ----- OS2REXX CFORUM appended at 13:00:45 on 92/07/07 GMT (by CONT00 at LEXVMK)
  3001. ..... OS2REXX CFORUM modified at 15:46:04 on 92/08/24 GMT (by CONT00 at LEXVMK)
  3002. Subject: Modifying/opening objects with SysCreateObject
  3003. Ref:     Append at 20:36:25 on 92/07/06 GMT (by SAMI3QU at OS2CUST)
  3004.  
  3005. not documented, not supported, not allowed...
  3006.  
  3007. Gregory Czaja, Lexington 8-545-3311  1992/07/07  08:39
  3008.  
  3009. ----- OS2REXX CFORUM appended at 17:32:55 on 92/07/07 GMT (by NAAC2VK at OS2CUST)
  3010. Subject: Querying Objects
  3011.  
  3012.   In OS/2 1.3 we created a couple of programs which use
  3013. PrfQueryTitles & PrfQueryDefinition to unload the various Group
  3014. menus a user has created and PrfCreateGroup & PrfAddProgram to
  3015. recreate them over the install of new level of Operating System.  I can see
  3016. in the example (FOLDER.CMD) how I can use the SysCreateObject to create
  3017. similiar information in folders.  My question - is there a query function
  3018. like WinCreateObject which can be used to query class information (e.g.,
  3019. <WPProgram>.
  3020.  
  3021. Joe Jankowski
  3022.  
  3023. ----- OS2REXX CFORUM appended at 20:25:31 on 92/07/07 GMT (by XXNOVA24 at TORVMCOP)
  3024. Subject: Separating Filaname and Ext.
  3025. How can I separate the filaname from the extention in REXX?
  3026. The following doesn't work:
  3027. /* Rexx */
  3028. parse arg filename '.' extention
  3029. say filename
  3030. say ''
  3031. say extention
  3032. exit
  3033.  
  3034. When I drop a file from one of my folder, the output is:
  3035. "C:\OS!2 2
  3036.  
  3037. 0 Desktop\My Test Folder\Test1.C"
  3038.  
  3039. It is split at the first '.' . How can I split it at the extention?
  3040.  
  3041. For the same reason the SOM compilers are not supporting the drag-drop.
  3042. HPFS Names.
  3043.  
  3044. Geza Szivos
  3045. NOVACOR Chemicals (403)-290-6583
  3046.  
  3047. ----- OS2REXX CFORUM appended at 20:54:54 on 92/07/07 GMT (by 64985842 at TOROHON1)
  3048. Subject: Separating Filaname and Ext.
  3049. Ref:     Append at 20:25:31 on 92/07/07 GMT (by XXNOVA24 at TORVMCOP)
  3050.  
  3051. How about something like this:
  3052.  
  3053.   pfn = Lastpos('.',filename)
  3054.   If pfn > 0
  3055.     Then extension = Substr(filename,pfn+1)
  3056.     Else extension = ''
  3057.  
  3058. Blair Thompson               BLAIR at CANVM2              IBM Canada Ltd.
  3059.  
  3060. ----- OS2REXX CFORUM appended at 21:29:57 on 92/07/07 GMT (by 86696089 at WARVM2)
  3061. Subject: Separating filename and extension
  3062. Ref:     Append at 20:25:31 on 92/07/07 GMT (by XXNOVA24 at TORVMCOP)
  3063.  
  3064. There is a better, but I can't quite remember it myself
  3065.  
  3066. OS/2 provides variables which hold the full filename, the drive,
  3067. the path, the extension, etc.
  3068.  
  3069. I know that the full filename is in the variable called %*,
  3070. but can anyone tell me what the other variables are?
  3071.  
  3072. (Something like %*P. for path, %*D, ...)
  3073.  
  3074. Andrew Wainwright
  3075. ...
  3076.  
  3077. ----- OS2REXX CFORUM appended at 21:58:04 on 92/07/07 GMT (by XXMINC08 at TORVMCOP)
  3078. Subject: Separating filename and extension
  3079. Ref:     Append at 21:29:57 on 92/07/07 GMT (by 86696089 at WARVM2)
  3080.  
  3081. Geza,
  3082.    There is a REXX built-in function which may help you.  It is called
  3083. FILESPEC and is used to separate a string into drive, path, and name
  3084. components.  Try the following
  3085.  
  3086.    filename = FILESPEC('name',ARG(1))
  3087. This should give you your 'test.c' in the filename variable, and then
  3088. you can use parse to strip off the extension.  Good luck.
  3089.  
  3090. Bill Nelson
  3091. Manulife Financial
  3092.  
  3093. ----- OS2REXX CFORUM appended at 22:07:45 on 92/07/07 GMT (by XXMINC08 at TORVMCOP)
  3094. Subject: SysIni Eats Memory???
  3095. Ref:     Append at 21:58:04 on 92/07/07 GMT (by XXMINC08 at TORVMCOP)
  3096.    I wrote a little command file to dump the contents of OS2.INI to
  3097. my printer.  It is quite simple and uses the SysIni utility function
  3098. to get access to the ini file.  It seems to work fine, however every
  3099. time I run it my swapper.dat increases by about 3MB.  I boot up my
  3100. machine, open an OS/2 window, run the .cmd file, check the size of
  3101. swapper.dat, run the .cmd file, re-check the size of swapper.dat and
  3102. it has increased by 3MB.  If I repeat the last two steps it increases
  3103. by another 3MB, and I can repeat this any number of times I want until
  3104. my partition is all used up.  Has anyone else noticed the SysIni function
  3105. or any other rexx procedures using up memory like this??
  3106. Bill Nelson
  3107. Manulife Financial
  3108.  
  3109. ----- OS2REXX CFORUM appended at 22:14:11 on 92/07/07 GMT (by XXNOVA24 at TORVMCOP)
  3110. Subject: Separating Filaname and Ext.
  3111. Ref:     Append at 20:54:54 on 92/07/07 GMT (by 64985842 at TOROHON1)
  3112.  
  3113. Thanks Blair, It works.
  3114.  
  3115. Geza Szivos
  3116. NOVACOR Chemicals (403)-290-6583
  3117.  
  3118. ----- OS2REXX CFORUM appended at 00:40:52 on 92/07/08 GMT (by XXHAYM01 at TORVMCOP)
  3119. Subject: SysIni Eats Memory???
  3120. Ref:     Append at 22:07:45 on 92/07/07 GMT (by XXMINC08 at TORVMCOP)
  3121.  
  3122. There have been a couple of fixes released that cause this problem.
  3123. There is a new kernel file that takes care of swapper.dat not reducing
  3124. in size, and some new REXX DLL's that take care of the fact that REXX
  3125. is eating memory and not releasing it.  Check on Compu$erve, or better
  3126. OS/2-oriented BBS's.
  3127.  
  3128. Tom Koschate
  3129. Hay Management Consultants
  3130. (416) 868-1371
  3131.  
  3132. ----- OS2REXX CFORUM appended at 12:16:22 on 92/07/08 GMT (by XXCDSX26 at TORVMCOP)
  3133. Subject: SysIni Eats Memory???
  3134. Ref:     Append at 22:07:45 on 92/07/07 GMT (by XXMINC08 at TORVMCOP)
  3135.  
  3136. Bill:
  3137.  
  3138. This is a known problem and there is an APAR for it (I reported it
  3139. a while back).  Unfortunately, the Support Centre has not gotten
  3140. back to me regarding a fix.
  3141.  
  3142. However, over on CompuServe (and other fine OS2 BBSs) there is a
  3143. file, REXX20.ZIP in Lib 17, that updates all the REXX DDLs.  This
  3144. will fix the problem.  Interestingly, an OS/2 user told me about
  3145. the fix while IBM has been quiet.
  3146.  
  3147. Michael Harper - Cdn Depository for Securities, Ltd
  3148.  
  3149. ----- OS2REXX CFORUM appended at 13:51:22 on 92/07/08 GMT (by SAMI3QU at OS2CUST)
  3150. Subject: SysIni Eats Memory???
  3151. Ref: Append at 12:16:22 on 92/07/08 GMT (by XXCDSX26 at TORVMCOP)
  3152.  
  3153. REXX20.ZIP is also available on this BBS in the OS/2 Software Library.
  3154. diskettes, and using XCOPY C:\*.* /S /E.
  3155.  
  3156. Mark Thompson - Coal Services Corp.  St. Louis, MO
  3157.  
  3158. ----- OS2REXX CFORUM appended at 14:39:46 on 92/07/08 GMT (by BRYAN at BCRVMPC1)
  3159. Subject: Separating filename and extension
  3160. Ref:     Append at 21:29:57 on 92/07/07 GMT (by 86696089 at WARVM2)
  3161.  
  3162. %**P      = Insert Drive and Path information without last backslash.
  3163. %**D      = Insert Drive with ':' or UNC name
  3164. %**N      = Insert file name without extension
  3165. %**F      = Insert file name with extention
  3166. %**E      = Insert extention without leading dot.  On HPFS, the
  3167.             extention is always what comes after the last dot.
  3168.  
  3169. Barry Bryan
  3170.  
  3171. ----- OS2REXX CFORUM appended at 14:50:57 on 92/07/08 GMT (by VERSTEEG at UITVM1)
  3172. Subject: Separating filename and extension
  3173. Ref:     Append at 21:29:57 on 92/07/07 GMT (by 86696089 at WARVM2)
  3174.  
  3175. I think you are referring to %**N (filename) and %**E (extension)
  3176. that can be specified in the parameter field of the program object.
  3177. This can be an alternative for the FILESPEC method mentioned earlier.
  3178.  
  3179. Anton Versteeg - ESAT PWS CoC Uithoorn, NL       *** GO OS/2 2.0 ***
  3180.  
  3181. ----- OS2REXX CFORUM appended at 15:25:55 on 92/07/08 GMT (by XXNOVA24 at TORVMCOP)
  3182. Subject: Separating filename and extension
  3183. Ref:     Append at 14:50:57 on 92/07/08 GMT (by VERSTEEG at UITVM1)
  3184.  
  3185. It still doesn't work.
  3186.  
  3187. /* Rexx */
  3188. parse arg filename
  3189. say filename
  3190. say %**N(filename)
  3191. exit
  3192.  
  3193. generates just an error message:
  3194. "C:\OS!2 2.0 Desktop\My Test Folder\Test1.C"
  3195.      4 +++   Say % ** N(filename);
  3196. REX0035: Error 35 running C:\RunHH.Cmd, line 4: Invalid expression
  3197.  
  3198. Geza Szivos
  3199. NOVACOR Chemicals (403)-290-6583
  3200.  
  3201. ----- OS2REXX CFORUM appended at 16:04:06 on 92/07/08 GMT (by VERSTEEG at UITVM1)
  3202. Subject: Separating filename and extension
  3203. Ref:     Append at 15:25:55 on 92/07/08 GMT (by XXNOVA24 at TORVMCOP)
  3204.  
  3205. The %**N and %**E go in the parameter field of the program object.
  3206. (create a program object from the program template, it's on the first
  3207. page of the notebook you see when you select open-->settings)
  3208. In the REXX program you can then do a Parse Arg name extension,
  3209. if you passed %**N and %**E as parameters.
  3210.  
  3211. Note that %**N and %**E, etc. get set when you drag/drop a file over
  3212. the program icon in question.
  3213.  
  3214. Anton Versteeg - ESAT PWS CoC Uithoorn, NL       *** GO OS/2 2.0 ***
  3215.  
  3216. ----- OS2REXX CFORUM appended at 19:12:21 on 92/07/08 GMT (by XXMINC08 at TORVMCOP)
  3217. Subject: SysIni Eats Memory???
  3218. Ref:     Append at 00:40:52 on 92/07/08 GMT (by XXHAYM01 at TORVMCOP)
  3219.  
  3220. Thanks Tom.  I did see some fixes for REXX on the OS/2 BBS here in
  3221. Toronto, but I haven't tried them yet.  I did try the new kernel fix
  3222. and it didn't make any difference.  Guess I'll give the REXX fixes
  3223. a try.
  3224.  
  3225. Bill Nelson
  3226. Manulife Financial
  3227.  
  3228. ----- OS2REXX CFORUM appended at 19:18:31 on 92/07/08 GMT (by XXMINC08 at TORVMCOP)
  3229. Subject: SysIni Eats Memory???
  3230. Ref:     Append at 12:16:22 on 92/07/08 GMT (by XXCDSX26 at TORVMCOP)
  3231.  
  3232. Thanks Michael.  I have seen the fixes for REXX around, but have not
  3233. given them a try yet.  Guess I'll do that.
  3234.  
  3235. Bill Nelson
  3236. Manulife Financial
  3237.  
  3238. ----- OS2REXX CFORUM appended at 19:19:41 on 92/07/08 GMT (by XXNOVA24 at TORVMCOP)
  3239. Subject: Separating filename and extension
  3240. Ref:     Append at 16:04:06 on 92/07/08 GMT (by VERSTEEG at UITVM1)
  3241.  
  3242. Thanks everyone.
  3243. Getting closer what I want. If I use "%**E" "%**N" "%**P"
  3244.  I get the Extention+ Name OK, BUT when I have spaces and dots in
  3245.  the filename and in the path the parse splits them at the spaces
  3246. and not at " ".
  3247.  
  3248. Actually, where did you guys get this %** business? Is it documented?
  3249.  
  3250. Geza Szivos
  3251. NOVACOR Chemicals (403)-290-6583
  3252.  
  3253. ----- OS2REXX CFORUM appended at 22:05:09 on 92/07/08 GMT (by IL22993 at OS2CUST)
  3254. Subject: How to delete entries from OS2SYS.INI
  3255.  
  3256. Does anyone have any suggestions for deleting some keys from the OS2SYS.INI?
  3257.  
  3258. I dragged a printer from my Novell server onto the desktop.  (Deleted and
  3259. retired total of 3 times).   The printers are all deleted however
  3260. PM_SPOOLER_QUEUE_DES   ...QUEUE_DD ...QUEUE.DDD  and ...PRINTER_D are
  3261. all out there duplicated 3 times, set to LANSPOOL, LANSPOO1, LANSPOO2.
  3262.  
  3263. Unfortunatly PM Print Screen chooses one of them to print to.
  3264.  
  3265. Is there any way to delete them?   the sys ini function in REXX seems to
  3266. not want to update the system ini files.
  3267.  
  3268. I really don't want to re-create my system only to delete some remanants
  3269. of some printers.
  3270.  
  3271. Thanks....
  3272.  
  3273. George Clark,   Norton Company
  3274.  
  3275. ----- OS2REXX CFORUM appended at 22:29:12 on 92/07/08 GMT (by XXMINC08 at TORVMCOP)
  3276. Subject: How to delete entries from OS2SYS.INI
  3277. Ref:     Append at 22:05:09 on 92/07/08 GMT (by IL22993 at OS2CUST)
  3278.  
  3279. George,
  3280.    I haven't tried this, but according to the documentation, the
  3281. following should do the trick.
  3282.  
  3283.   call SysIni 'SYSTEM', 'APP_NAME'
  3284.  
  3285. this is supposed to delete all keys for application APP_NAME.
  3286. Good luck!
  3287.  
  3288. Bill Nelson
  3289. Manulife Financial
  3290.  
  3291. ----- OS2REXX CFORUM appended at 22:34:49 on 92/07/08 GMT (by XXMINC08 at TORVMCOP)
  3292. Subject: Separating filename and extension
  3293. Ref:     Append at 19:19:41 on 92/07/08 GMT (by XXNOVA24 at TORVMCOP)
  3294.  
  3295. Geza,
  3296.    The documentation for these parameters is found as follows.
  3297. Display the popup menu for any program reference object.  Choose Open
  3298. Settings, position the cursor in the "Parameters" field, push the Help
  3299. pushbutton.  The online help for this "Parameters" field now describes
  3300. each of these options.
  3301.  
  3302. Bill Nelson
  3303. Manulife Financial
  3304.  
  3305. ----- OS2REXX CFORUM appended at 22:54:40 on 92/07/08 GMT (by PMUELLR at CARVM3)
  3306. Subject: Separating filename and extension
  3307. Ref:     Append at 19:19:41 on 92/07/08 GMT (by XXNOVA24 at TORVMCOP)
  3308.  
  3309. In this case, I think you'd be better off passing the ENTIRE file name
  3310. to the rexx program, and then splitting it apart with filespec().
  3311. You're not going to be able to tell spaces in the filename from spaces
  3312. in the parameter list otherwise.
  3313.  
  3314. filespec() won't give you the extension, but you already have examples
  3315. of how to do this.  I might have done:
  3316.  
  3317.    parse value reverse(wholeFileName) with reverseExt "." .
  3318.    ext = reverse(reverseExt)
  3319.  
  3320. (assuming you know there IS an extension)
  3321.  
  3322. Patrick Mueller - IBM Cary
  3323.  
  3324. ----- OS2REXX CFORUM appended at 03:55:12 on 92/07/09 GMT (by XXNOVA24 at TORVMCOP)
  3325. Subject: Separating filename and extension
  3326. Ref:     Append at 22:34:49 on 92/07/08 GMT (by XXMINC08 at TORVMCOP)
  3327.  
  3328. Bill,
  3329.   Thanks. I will spend a few days to push PF1 . It was so dangrous
  3330. during the EEP what I stopped using it.
  3331.  
  3332. Geza Szivos
  3333. NOVACOR Chemicals (403)-290-6583
  3334.  
  3335. ----- OS2REXX CFORUM appended at 16:28:28 on 92/07/10 GMT (by NOLINDB at OS2CUST)
  3336. Subject: rexx20 fixes
  3337.  
  3338. I applied the REXX20 fixes from this forum and find that PMREXX fails after
  3339. application.
  3340.  
  3341.       8 +++   SAY 'ENTER ONE';
  3342.  REX0048: ERROR 48 RUNNING C:\STOCK.CMD, LINE 8: FAILURE IN SYSTEM SERVICE
  3343.  
  3344. I followed the instructions in REXX.TXT (not too hard to copy 4 files).
  3345. (I booted off floppies, copied files to c:\os2\dll, rebooted.)
  3346.  
  3347. Am I missing something or is there a problem?
  3348.  
  3349. Ned
  3350.  
  3351. ----- OS2REXX CFORUM appended at 20:47:17 on 92/07/10 GMT (by SAMI3QU at OS2CUST)
  3352. Subject: rexx20 fixes
  3353. Ref: Append at 16:28:28 on 92/07/10 GMT (by NOLINDB at OS2CUST)
  3354.  
  3355. Ned,
  3356.  
  3357.   I had the same problem.  I had to roll the fix off to get PMREXX apps to
  3358. work again.
  3359.  
  3360. Mark Thompson - Coal Services Corp.  St. Louis, MO
  3361.  
  3362. ----- OS2REXX CFORUM appended at 18:54:50 on 92/07/12 GMT (by MRTOM at YKTVMV)
  3363. ..... OS2REXX CFORUM modified at 18:58:17 on 92/07/12 GMT (by MRTOM at YKTVMV)
  3364. Subject: Separating Filaname and Ext.
  3365. Ref:     Append at 20:25:31 on 92/07/07 GMT (by XXNOVA24 at TORVMCOP)
  3366.          Append at 20:54:54 on 92/07/07 GMT (by 64985842 at TOROHON1)
  3367.          Append at 22:54:40 on 92/07/08 GMT (by PMUELLR at CARVM3)
  3368.  
  3369. Blair, Patrick,
  3370. Your code will not work if the directory contains a dot and the filename
  3371. does not (C:\TEMP.DIR\FILE, for instance).
  3372.  
  3373. Try this:
  3374.  
  3375. /* */
  3376. parse arg Fullname
  3377. parse value filespec('NAME', Fullname) with Filename '.' Extension
  3378.  
  3379. Tom
  3380.  
  3381. ----- OS2REXX CFORUM appended at 11:45:16 on 92/07/13 GMT (by MCGUIRE at GDLVM7)
  3382. Subject: rexx20 fixes
  3383. Ref:     Append at 16:28:28 on 92/07/10 GMT (by NOLINDB at OS2CUST)
  3384.  
  3385. Yes, known problem.  There should be an updated version of REXX20 available
  3386. shortly (probably by the end of the day).
  3387.  
  3388. Rick McGuire - SAA Rexx Development, Endicott
  3389.  
  3390. ----- OS2REXX CFORUM appended at 16:52:04 on 92/07/13 GMT (by XXNOVA24 at TORVMCOP)
  3391. Subject: Separating Filaname and Ext.
  3392. Ref:     Append at 18:54:50 on 92/07/12 GMT (by MRTOM at YKTVMV)
  3393.  
  3394. Getting closer , but not right. Try with the following legal HPFS
  3395. names:
  3396.  
  3397. Directory (folder Name)
  3398. C:\A.very Long student.csc with ..multiple dots
  3399. FileName:
  3400. spaces  and ... dots in the.filename.csc
  3401.  
  3402. Adding the printout for your example:
  3403. say fullname
  3404. say filename
  3405. say extension
  3406. Results the following output:
  3407. "C:\A.very Long student.csc with ..multiple dots\spaces  and ... dots in
  3408.  the.filename.csc"
  3409. spaces  and
  3410. .. dots in the.filename.csc"
  3411.  
  3412. Geza Szivos
  3413. NOVACOR Chemicals (403)-290-6583
  3414.  
  3415. ----- OS2REXX CFORUM appended at 17:22:32 on 92/07/13 GMT (by WZ00533 at OS2CUST)
  3416. Subject: SysCreateObject
  3417.  
  3418. Some place on this BBS I saw an explanation of an undocumented parameter
  3419. to SysCreateObject which had something to do with adding the object,
  3420. updating the object and failing if the object existed.
  3421.  
  3422. I spent the last hour searching for the append to no avail.
  3423.  
  3424. Can someone enlighten me?
  3425.  
  3426. Thanks,
  3427.  
  3428. Dave Ferrey - Bethlehem Steel Corp - Bethlehem PA
  3429.  
  3430. ----- OS2REXX CFORUM appended at 17:34:30 on 92/07/13 GMT (by MCGUIRE at GDLVM7)
  3431. Subject: SysCreateObject
  3432. Ref:     Append at 17:22:32 on 92/07/13 GMT (by WZ00533 at OS2CUST)
  3433.  
  3434. There is a very lengthy append in this forum (by Mike Lamb) that explains a
  3435. lot of the SysCreateObject usage.  There is also some information about the
  3436. extra parameter in the OS/2 2.0 README file.
  3437.  
  3438. Rick McGuire - SAA Rexx Development, Endicott
  3439.  
  3440. ----- OS2REXX CFORUM appended at 17:58:54 on 92/07/13 GMT (by XXCDSX26 at TORVMCOP)
  3441. Subject: SysCreateObject
  3442. Ref:     Append at 17:34:30 on 92/07/13 GMT (by MCGUIRE at GDLVM7)
  3443.  
  3444. Rick:
  3445.  
  3446. Is this a newer REXX20 than 6/17?
  3447.  
  3448. Michael Harper - Cdn Depository for Securities, Ltd
  3449.  
  3450. ----- OS2REXX CFORUM appended at 18:21:53 on 92/07/13 GMT (by MCGUIRE at GDLVM7)
  3451. Subject: SysCreateObject
  3452. Ref:     Append at 17:58:54 on 92/07/13 GMT (by XXCDSX26 at TORVMCOP)
  3453.  
  3454. Yes, this update is newer than the 6/17 update.
  3455.  
  3456. Rick McGuire - SAA Rexx Development, Endicott
  3457.  
  3458. ----- OS2REXX CFORUM appended at 19:11:28 on 92/07/13 GMT (by MIKELAMB at KGNVMC)
  3459. Subject: Querying Objects
  3460. Ref:     Append at 17:32:55 on 92/07/07 GMT (by NAAC2VK at OS2CUST)
  3461.  
  3462. As far as I know there is no Winxxx call that can dump the information
  3463. you would need to recreate an object. Beside information about the
  3464. object being in your INI file it's also got ties into the EA's.
  3465.  
  3466. If you were moving a bunch of folks from 1.3 to 2.0 you could write
  3467. a routine that took a dump of 1.3's INI and converted them to Rexx
  3468. calls to recreate groups and program objects.
  3469.  
  3470.               Michael A. Lamb  (MIKELAMB @ KGNVMC)  1992/07/13 15:07 EDT
  3471.  
  3472. ----- OS2REXX CFORUM appended at 19:14:05 on 92/07/13 GMT (by MIKELAMB at KGNVMC)
  3473. Subject: REXXUTIL Information and Samples
  3474. Ref:     Append at 12:37:10 on 92/06/19 GMT (by MIKELAMB at KGNVMC)
  3475.  
  3476. I've updated the append referenced to give a few more
  3477. examples of SysCreateObject and it adds descriptions of the newer
  3478. function calls provided by the REXX20 fixes/enhancements (Thanks Rick
  3479. McGuire). Also changed the CONCURRENTVIEW to CCVIEW items mentioned
  3480. earlier in a FORUM (Thanks Dan Kehn, Felix Sawicki).
  3481.  
  3482. The sample code contains:
  3483.  
  3484. (STARTDOS.CMD)
  3485. Starts a DOS program using specific DOS VDM settings.
  3486. (BOOTDOS.CMD)
  3487. Starts a DOS session, booting from a specific DOS image with
  3488. specific DOS VDM settings.
  3489. (REBUILD.CMD)
  3490. Allows one to rebuild OS/2 system objects, like MAKEINI does.
  3491. (LPTADD.CMD)
  3492. Code using SysIni to add LPT4-9 ports.
  3493.  
  3494. As always if you find items of interest using some of the REXXUTIL
  3495. functions please let me know... Thanks...
  3496.  
  3497.               Michael A. Lamb  (MIKELAMB @ KGNVMC)  1992/07/13 15:11 EDT
  3498.  
  3499. ----- OS2REXX CFORUM appended at 22:20:08 on 92/07/13 GMT (by MRTOM at YKTVMV)
  3500. Subject: Separating Filaname and Ext.
  3501. Ref:     Append at 16:52:04 on 92/07/13 GMT (by XXNOVA24 at TORVMCOP)
  3502.  
  3503. Well, that was obviously left as an exercise for further study. :-)
  3504.  
  3505. But since you asked, take your pick:
  3506.  
  3507. /* */
  3508. parse arg Full
  3509. Name = filespec('NAME', Full)
  3510. Dot = lastpos('.', Name)
  3511. if Dot > 0
  3512.   then do; Ext = substr(Name, Dot+1);Name = left(Name, Dot-1);  end
  3513.   else Ext = ''
  3514. say
  3515. say '>' Name
  3516. say '>' Ext
  3517.  
  3518. /* */
  3519. parse arg Full
  3520. parse value reverse(filespec('NAME', Full)) with Ext '.' Name
  3521. Ext = reverse(Ext)
  3522. Name = reverse(Name)
  3523. say
  3524. say '>' Name
  3525. say '>' Ext
  3526.  
  3527. Tom
  3528.  
  3529. ----- OS2REXX CFORUM appended at 15:02:49 on 92/07/14 GMT (by CS04116 at OS2CUST)
  3530. Subject: Starting a REXX procedure from a DOS session
  3531.  
  3532. I have an application that I would like to start a REXX procedure.
  3533. Unfortunately, the application is in DOS.
  3534.  
  3535. Is there anyway I can start a REXX procedure from a DOS session?
  3536.  
  3537. CS04116
  3538.  
  3539. ----- OS2REXX CFORUM appended at 18:09:06 on 92/07/14 GMT (by BRENT at DALVM41B)
  3540. Subject: rexx20 fixes
  3541. Ref: Append at 11:45:16 on 92/07/13 GMT (by MCGUIRE at GDLVM7)
  3542.  
  3543. The new REXX20 fix package (V 1.02) is now available for download.
  3544.  
  3545. Brent Allen - IBM OS/2 Base Services Support
  3546.  
  3547. ----- OS2REXX CFORUM appended at 12:38:02 on 92/07/15 GMT (by MIKELAMB at KGNVMC)
  3548. Subject: REXXUTIL Information and Samples
  3549. Ref:     Append at 19:14:05 on 92/07/13 GMT (by MIKELAMB at KGNVMC)
  3550.  
  3551. The append I made the other day got truncated so I've fixed that and also
  3552. added a couple more samples:
  3553. - (OBJECTID.CMD)
  3554.   Code using SysIni to list OBJECTIDs known to the WorkPlace Shell
  3555. - (FONTS.CMD)
  3556.   Code using SysIni to list installed fonts.
  3557.  
  3558.               Michael A. Lamb  (MIKELAMB @ KGNVMC)  1992/07/15 08:35 EDT
  3559.  
  3560. ----- OS2REXX CFORUM appended at 19:21:00 on 92/07/15 GMT (by TCC3824 at OS2CUST)
  3561. Subject: REXXUTIL
  3562.  
  3563. 1) Is there any way to add menu items to a folder using syscreateobject
  3564.    or syssetobjectdata?
  3565.  
  3566. I am having problems getting the following to work with rexxutil:
  3567. I am using the new rexx20 code as of 7-14-92.
  3568.  
  3569. 1) Set a background to a folder, the folder is created ok.
  3570.    When I open the folder the background does not show up.
  3571.    If I select the background tab in settings the background shows up.
  3572.    Ideas?  bug?
  3573.  
  3574. 2) I have added a program with the VIEW.EXE as the pgm, an inf file
  3575.    as the parm and a dir for the working dir.
  3576.    When I select the pgm icon an os/2 window opens a closes. no inf display..
  3577.  
  3578.    If I select a pgm template and add the same settings it works fine.
  3579.    Ideas?  bug
  3580.  
  3581. Kevin McConnell   512-338-7457  Continuum    Austin Tx
  3582.  
  3583. ----- OS2REXX CFORUM appended at 19:36:40 on 92/07/15 GMT (by SHABBY at RCHVMP)
  3584. Subject: REXXUTIL
  3585. Ref:     Append at 19:21:00 on 92/07/15 GMT (by TCC3824 at OS2CUST)
  3586.  
  3587. 1) Is there a toggle you have to set to get it out of "Color" mode for
  3588. the background?  You can set the background but still have it set to
  3589. a solid color with the radio button there.
  3590.  
  3591. -Chris
  3592.  
  3593. ----- OS2REXX CFORUM appended at 18:10:52 on 92/07/16 GMT (by CHVY006 at OS2CUST)
  3594. Subject: REXX and RAM
  3595.  
  3596. How can a REXX program get a:
  3597. SYS0008: There is not enough storage available to
  3598. process this command. All available storage is in use.
  3599.  
  3600. The first thing I did was to check the swapper.dat size and time stamped
  3601. at the time of failure and it was not touched for at least an hour.
  3602. The swapper was less than 1mb and I still had 28mb of DASD free.
  3603. This machine has 10mb of ram.
  3604.  
  3605. I most confess that I am using two dll which I register and call a number of
  3606. times.
  3607.  
  3608. A litle description of the program's function goes as follows:
  3609. It is a collection of rexx programs that communicate with each other with
  3610. multiple rexx queues (about 6). One DLL performs 3270 EHLLAPI call and the
  3611. other some minor and not critical aesthetic functions.
  3612. This program functions as a 3270 scripting for host access.
  3613.  
  3614. The program was almost done until I got that sys0008 message.
  3615. I do get the message under both OS/2 2.0 and OS/2 1.3 on various workstations.
  3616.  
  3617. Carlton Brewster, Chevy Chase F.S.B.
  3618.  
  3619. ----- OS2REXX CFORUM appended at 19:31:30 on 92/07/16 GMT (by PMUELLR at CARVM3)
  3620. Subject: REXX and RAM
  3621. Ref:     Append at 18:10:52 on 92/07/16 GMT (by CHVY006 at OS2CUST)
  3622.  
  3623. It doesn't sounds like this is your problem, but a common mistake when
  3624. writing external function dlls is when the dll doesn't return 0.
  3625. Returning a non-zero value from the C function that implements the
  3626. rexx function causes rexx to generate an error - returning 40 means
  3627. syntax error, returning 5 means machine storage exhausted, etc.  You
  3628. might want to check your code to make sure you are returning 0
  3629. all the time, unless you specifically want the interpreter to get
  3630. an error in those cases.
  3631.  
  3632. Patrick Mueller - IBM Cary
  3633.  
  3634. ----- OS2REXX CFORUM appended at 12:37:20 on 92/07/20 GMT (by MCGUIRE at GDLVM7)
  3635. Subject: REXX and RAM
  3636. Ref:     Append at 19:31:30 on 92/07/16 GMT (by PMUELLR at CARVM3)
  3637.  
  3638. The SYS0008 message is from CMD.EXE, not from Rexx.  There are two
  3639. possibilities that I'm aware of:
  3640.  
  3641. 1)  One of your DLLs is allocating storage and not releasing it, causing the
  3642. process to run out of selectors.  While your swapper is still low, there are
  3643. no selectors for additional segments available in the process.
  3644.  
  3645. 2)  You are invoking your DLLs using the C type calling convention:
  3646.  
  3647.    foo(a, b, c)
  3648.  
  3649. AND the DLLs are returning null strings.  Since by Rexx rules, that type of
  3650. instruction is a COMMAND, the null string is passed to CMD.EXE.  There is a
  3651. known problem that CMD.EXE starts issuing SYS0008 messages after it has
  3652. received a number of these null commands.  To fix the problem, change the
  3653. call to one of the following:
  3654.  
  3655.    temp = foo(a, b, c)
  3656.  
  3657.      or
  3658.  
  3659.    call foo a, b, c
  3660.  
  3661. Rick McGuire - SAA Rexx Development, Endicott
  3662.  
  3663. ----- OS2REXX CFORUM appended at 18:35:08 on 92/07/20 GMT (by PPBKR at OS2CUST)
  3664. Subject: Querying Objects
  3665. Ref: Append at 17:32:55 on 92/07/07 GMT (by NAAC2VK at OS2CUST)
  3666.  
  3667. I am interested in finding a function similiar to PrfQueryProgramTitles
  3668. also.  It would be nice if there was a REXXUTIL function called
  3669. SysQueryObject that provided information about objects within a
  3670. particular folder.
  3671.  
  3672. I have a folder, that should only contain certain objects, so I need
  3673. a way to query the objectID's of each object within that folder.
  3674.  
  3675. If anyone knows of a way, I would be interested in hearing it also.
  3676.  
  3677. Thanks,
  3678.  
  3679. BK Rogers  Phillips Petroleum
  3680.  
  3681. ----- OS2REXX CFORUM appended at 22:46:54 on 92/07/20 GMT (by XXWESB22 at TORVMCOP)
  3682. Subject: Starting Programs from Startup.cmd
  3683.  
  3684. I am trying to start a windows program using Startup.cmd. I have no
  3685. problems starting it with the command "start /win d:\path\filename"
  3686. but it is then not available from the desktop as an object.  Is there
  3687. a way from the startup.cmd file to start an object from the desktop
  3688. even if the desktop has not finished coming up??
  3689.  
  3690. ADVthanksANCE
  3691.  
  3692. Gareth Jones
  3693. ISM - Information Systems Management
  3694. Regina, SK Phone (306) 781-5109
  3695.  
  3696. ----- OS2REXX CFORUM appended at 12:30:45 on 92/07/21 GMT (by MCGUIRE at GDLVM7)
  3697. Subject: Starting Programs from Startup.cmd
  3698. Ref:     Append at 22:46:54 on 92/07/20 GMT (by XXWESB22 at TORVMCOP)
  3699.  
  3700. You can use SysCreateObject or SysSetObjectData to open an object.  For
  3701. example,
  3702.  
  3703.   call rxfuncadd 'SysLoadFuncs', 'REXXUTIL', 'SysLoadFuncs'
  3704.   call sysloadfuncs
  3705.   call syssetobjectdata '<WP_OS2SYS>', 'OPEN=DEFAULT;'
  3706.  
  3707. Opens the System folder when the system is booted.  In general, the object
  3708. should be given an object id or already have one to work.  Also, to use
  3709. SysSetObjectData, you'll need the latest REXXUTIL.DLL from REXX20.ZIP.
  3710.  
  3711. Rick McGuire - SAA Rexx Development, Endicott
  3712.  
  3713. ----- OS2REXX CFORUM appended at 17:56:36 on 92/07/21 GMT (by HRIVERA at PKMFGVM5)
  3714. Subject: Minimized VIO window in OS/2 1.3
  3715.  
  3716. Is there a way that a REXX CMD can force the OS/2 window it's running
  3717. under to be minimized from within the REXX code itself?
  3718. Thanks!
  3719.  
  3720. Hector L. Rivera
  3721.  
  3722. ----- OS2REXX CFORUM appended at 19:14:33 on 92/07/21 GMT (by EKARSTEN at DETVMIC4)
  3723. Subject: Trapping Control Break
  3724. Is there away to trap Control Break or turn it off in a REXX procedure?
  3725.  
  3726. Eric Karsten
  3727.  
  3728. ----- OS2REXX CFORUM appended at 20:27:26 on 92/07/21 GMT (by MCGUIRE at GDLVM7)
  3729. Subject: Trapping Control Break
  3730. Ref:     Append at 19:14:33 on 92/07/21 GMT (by EKARSTEN at DETVMIC4)
  3731.  
  3732. Signal On Halt or Call On Halt will trap a cntrl-break.
  3733.  
  3734. Rick McGuire - SAA Rexx Development, Endicott
  3735.  
  3736. ----- OS2REXX CFORUM appended at 20:27:58 on 92/07/21 GMT (by SBSTBE4 at OS2CUST)
  3737. Subject: OS2REXX and 3270 ehllapi
  3738.  
  3739. Is it possible to use rexx and ehllapi to control a 3270 session?  if so, where
  3740. is documented and are there any samples available?  Thank you
  3741.  
  3742. john r Miranda
  3743.  
  3744. ----- OS2REXX CFORUM appended at 20:45:41 on 92/07/21 GMT (by MCGUIRE at GDLVM7)
  3745. Subject: OS2REXX and 3270 ehllapi
  3746. Ref:     Append at 20:27:58 on 92/07/21 GMT (by SBSTBE4 at OS2CUST)
  3747.  
  3748. EHLLAPI support is available with Extended Services.  To access it, you need
  3749. to install the Communications Manager APIs.  In the API files, you'll find
  3750. a RXHLLAPI.DOC file, which describes the Rexx EHLLAPI interface.  Once you
  3751. have that, the access is pretty as described in the EHLLAPI reference.  I
  3752. don't have any examples of this handy, but maybe some kind soul can include
  3753. an example.
  3754.  
  3755. Rick McGuire - SAA Rexx Development, Endicott
  3756.  
  3757. ----- OS2REXX CFORUM appended at 20:51:11 on 92/07/21 GMT (by XXNOVA24 at TORVMCOP)
  3758. Subject: OS2REXX and 3270 ehllapi
  3759. Ref:     Append at 20:27:58 on 92/07/21 GMT (by SBSTBE4 at OS2CUST)
  3760.  
  3761. Yes. Look around the OS2CM CFORUM.
  3762.  
  3763. Geza Szivos
  3764. NOVACOR Chemicals (403)-290-6583
  3765. NHO-32 801-7th Ave Calgary, Alberta, CANADA  T2P 2N6
  3766.  
  3767. ----- OS2REXX CFORUM appended at 21:05:39 on 92/07/21 GMT (by EKARSTEN at DETVMIC4)
  3768. Subject: Trapping Control Break
  3769. Ref:      Append  at 20:27:26 on 92/07/21 GMT (by MCGUIRE at GDLVM7)
  3770. Thanks for the quick response!
  3771.  
  3772. Eric Karsten
  3773.  
  3774. ----- OS2REXX CFORUM appended at 17:56:07 on 92/07/22 GMT (by PRCI041 at OS2CUST)
  3775. Subject: SysCreateObject and Rexx Samples
  3776.  
  3777. I just downloaded the new RexxUtils samples in Mike Lamb's earlier append.  I
  3778. copied out FOLDER.CMD section of the program and ran it on my machine.  It
  3779. creates the folder and adds icons to the folder.  Yet, it appears that the
  3780. EXENAME settings doesn't work properly - there is no entry in the program
  3781. name field.  Subsequently when you try to run the newly created object, you
  3782. get the settings screen.  Am I misunderstanding how the SysCreateObject
  3783. function works (I assume it creates a fully runable object)?  When I ran
  3784. the SHADOW.CMD portion, it does create real shadows of the clock, but the
  3785. original object for SYSLEVEL.EXE and its shadow both do not contain any
  3786. data on the first page of the settings.
  3787.  
  3788. Mark Polly - Progressive Insurance
  3789.  
  3790. ----- OS2REXX CFORUM appended at 21:14:38 on 92/07/22 GMT (by XXNOVA24 at TORVMCOP)
  3791. Subject: SysCreateObject and Rexx Samples
  3792. Ref:     Append at 17:56:07 on 92/07/22 GMT (by PRCI041 at OS2CUST)
  3793.  
  3794. Those detailes should be on one line, this is the error.
  3795. You should change the :
  3796.  
  3797. setup='OBJECTID=<TEST_SYSL>;',
  3798.       'EXENAME=\OS2\SYSLEVEL.EXE;',
  3799.       'PROGTYPE=FULLSCREEN;'
  3800.  
  3801. to the
  3802.  
  3803. setup='OBJECTID=<TEST_SYSL>;EXENAME=\OS2\SYSLEVEL.EXE;PROGTYPE=FULLSCREEN
  3804.  
  3805. or use the
  3806.  
  3807. set1 ='OBJECTID=<TEST_SYSL>;'
  3808. set2 ='EXENAME=\OS2\SYSLEVEL.EXE;'
  3809. set3 ='PROGTYPE=FULLSCREEN;'
  3810. setup=set1|set2|set3
  3811.  
  3812. Geza Szivos
  3813. NOVACOR Chemicals (403)-290-6583
  3814. NHO-32 801-7th Ave Calgary, Alberta, CANADA  T2P 2N6
  3815.  
  3816. ----- OS2REXX CFORUM appended at 12:35:31 on 92/07/23 GMT (by CONT00 at LEXVMK)
  3817. Subject: SysCreateObject and Rexx Samples
  3818. Ref:     Append at 21:14:38 on 92/07/22 GMT (by XXNOVA24 at TORVMCOP)
  3819.  
  3820. Change this:
  3821. > setup=set1|set2|set3
  3822. to:
  3823.   setup=set1||set2||set3
  3824.  
  3825. Gregory Czaja, Lexington 8-545-3311  1992/07/23  08:34
  3826.  
  3827. ----- OS2REXX CFORUM appended at 13:04:01 on 92/07/23 GMT (by PERSHNG at YKTVMH)
  3828. Subject: SysCreateObject and Rexx Samples
  3829. Ref:     Append at 21:14:38 on 92/07/22 GMT (by XXNOVA24 at TORVMCOP)
  3830.  
  3831. Note that the statement:
  3832.  
  3833.     setup='OBJECTID=<TEST_SYSL>;',
  3834.           'EXENAME=\OS2\SYSLEVEL.EXE;',
  3835.           'PROGTYPE=FULLSCREEN;'
  3836.  
  3837. will insert an extraneous blank between the three clauses, which is
  3838. probably the cause of the problem.  The trailing comma tells REXX to
  3839. "glue" the next line onto this line with one intervening space, yielding:
  3840.  
  3841.     setup='OBJECTID=<TEST_SYSL>;' 'EXENAME=\OS2\SYSLEVEL.EXE;' 'PROGTYPE=FULLSCREEN;'
  3842.  
  3843. which is (probably?) wrong in this case.
  3844.  
  3845. Mashing this together onto one long string will work, as will the
  3846. explicit use of the concatenation operator (common usage):
  3847.  
  3848.     setup='OBJECTID=<TEST_SYSL>;',
  3849.         ||'EXENAME=\OS2\SYSLEVEL.EXE;',
  3850.         ||'PROGTYPE=FULLSCREEN;'
  3851.  
  3852. which tells REXX to glue the strings together *without* the spaces.
  3853.  
  3854. John A. Pershing Jr.
  3855.  
  3856. ----- OS2REXX CFORUM appended at 14:16:07 on 92/07/23 GMT (by CHVY006 at OS2CUST)
  3857. Subject: OS2REXX and 3270 ehllapi
  3858. Ref: Append at 20:45:41 on 92/07/21 GMT (by MCGUIRE at GDLVM7)
  3859.  
  3860. I'm working with the 32 bit ehllapi for ES and have the following comments:
  3861. 1.It would be nice to be able to call those 3270 functions using either the
  3862. function number or the function name. Example: Call hllapi 'connect' is
  3863. ok but not Call hllapi '1'. Yes I can always front-end the hllapi with a
  3864. preprocessor that does the conversion, but...
  3865. 2.It will be nice to have this interface officially documented with a manual
  3866. to give it some validity.
  3867. 3.I'm sure to find other "features/bugs" but now this is what I've found:
  3868. On functions that return "data strings" no return code is given. For instance:
  3869. Call hllapi 'copy_PS'  or Call hllapi 'copy_OIA'
  3870. How would I tell that on a copy_PS function call, the 3270 session was locked
  3871. or inhibited or busy if I don't get back return code just data. Result holds
  3872. the data. We need here another "hllapi global" variable to signal RC on these
  3873. type of calls.
  3874.  
  3875. Carlton Brewster, Chevy Chase F.S.B.
  3876.  
  3877. ----- OS2REXX CFORUM appended at 16:16:11 on 92/07/23 GMT (by SDETWEIL at DETVMIC4)
  3878. ..... OS2REXX CFORUM modified at 17:39:51 on 92/07/23 GMT (by SDETWEIL at DETVMIC4)
  3879. Subject: OS2REXX and 3270 ehllapi
  3880. Ref:     Append at 14:16:07 on 92/07/23 GMT (by CHVY006 at OS2CUST)
  3881.  
  3882. As the original developer of this function package, (since 1.1)
  3883. I'd like to answer your questions and see if I can understand
  3884. a little more.
  3885.  
  3886. 1.It would be nice to be able to call those 3270 functions using either the
  3887. function number or the function name. Example: Call hllapi 'connect' is
  3888. ok but not Call hllapi '1'. Yes I can always front-end the hllapi with a
  3889. preprocessor that does the conversion, but...
  3890.  
  3891. | I hate numbers. Rexx is a TEXT language. If I had made unique
  3892. | functions for each of the matching HLLAPI functions, this would
  3893. | have made it pretty convoluted..
  3894. |
  3895. | Why use numbers? The text makes it more readable, understandable,
  3896. | maintainable, simpler to use, and more easily learned.
  3897. |
  3898. | I'm NOT saying you're wrong (altho I personally think you are,
  3899. | but I'm trying to understand)
  3900.  
  3901. 2.It will be nice to have this interface officially documented with a manual
  3902. to give it some validity.
  3903.  
  3904. | S04G-1027, ES EHLLAPI manual. Same text as in RXHLLAPI.DOC
  3905.  
  3906. 3.I'm sure to find other "features/bugs" but now this is what I've found:
  3907. On functions that return "data strings" no return code is given. For instance:
  3908. Call hllapi 'copy_PS'  or Call hllapi 'copy_OIA'
  3909. How would I tell that on a copy_PS function call, the 3270 session was locked
  3910. or inhibited or busy if I don't get back return code just data. Result holds
  3911. the data. We need here another "hllapi global" variable to signal RC on these
  3912. type of calls.
  3913.  
  3914. | yep, pretty hard to have two answers with only one return value
  3915. | one should/could use Set_Session_Parms=NWAIT, then use the
  3916. | HLLAPI('WAIT') function to test the state of the device
  3917. | BEFORE the COPY_PS function. You'll have to have this code
  3918. | anyhow to make it reliable, so the thought was that you would
  3919. | check either BEFORE or AFTER if the returned string was a null
  3920. | string.
  3921. |
  3922. |  Compare the two logic sets,
  3923. |
  3924. |  if length(string)==0 then do  /* no data */
  3925. |      if special_var=5 then do  /* locked */
  3926. |      blah blah
  3927. |      end
  3928. |  end
  3929. |
  3930. | versus
  3931. |
  3932. |  if length(string)==0 then do    /* no data */
  3933. |      if HLLAPI('WAIT')=5 then do /* locked */
  3934. |      blah blah
  3935. |      end
  3936. |  end
  3937.  
  3938. Sam
  3939.  
  3940. ----- OS2REXX CFORUM appended at 16:37:06 on 92/07/23 GMT (by PRCI041 at OS2CUST)
  3941. Subject: SysCreateObject and Rexx Samples
  3942. Ref: Append at 13:04:01 on 92/07/23 GMT (by PERSHNG at YKTVMH)
  3943.  
  3944. Thanks for the help.  I had concatenated the separate lines into one,
  3945. but I did leave a blank space after each semicolon.  Removing the blanks
  3946. did the trick.
  3947.  
  3948. Mark Polly - Progressive Insurance
  3949.  
  3950. ----- OS2REXX CFORUM appended at 14:15:49 on 92/07/24 GMT (by MIKELAMB at KGNVMC)
  3951. ..... OS2REXX CFORUM modified at 18:31:38 on 92/07/24 GMT (by MIKELAMB at KGNVMC)
  3952. Subject: SysCreateObject and Rexx Samples
  3953. Ref:     Append at 16:37:06 on 92/07/23 GMT (by PRCI041 at OS2CUST)
  3954. Ref:     Append at 13:04:01 on 92/07/23 GMT (by PERSHNG at YKTVMH)
  3955. Ref:     Append at 12:35:31 on 92/07/23 GMT (by CONT00 at LEXVMK)
  3956. Ref:     Append at 21:14:38 on 92/07/22 GMT (by XXNOVA24 at TORVMCOP)
  3957. Ref:     Append at 17:56:07 on 92/07/22 GMT (by PRCI041 at OS2CUST)
  3958.  
  3959. Sorry all, Rick sent me a note offline describing my err...
  3960. I haven't had much time to follow the FORUM. I'll make the change this
  3961. weekend and replace the append in this FORUM. I also have yet
  3962. another example to add to it.
  3963.  
  3964.               Michael A. Lamb  (MIKELAMB @ KGNVMC)  1992/07/24 14:31 EDT
  3965.  
  3966. ----- OS2REXX CFORUM appended at 14:26:43 on 92/07/24 GMT (by TCC3824 at OS2CUST)
  3967. Subject: REXXUTIL
  3968. Ref: Append at 19:36:40 on 92/07/15 GMT (by SHABBY at RCHVMP)
  3969.  
  3970. There is no such option that I can see.
  3971.  
  3972. Kevin McConnell   512-338-7457  Continuum    Austin Tx
  3973.  
  3974. ----- OS2REXX CFORUM appended at 17:13:15 on 92/07/24 GMT (by XXMUTL27 at TORVMCOP)
  3975. Subject: GetEA and extended attributes
  3976. Ref:     Append at 16:37:06 on 92/07/23 GMT (by PRCI041 at OS2CUST)
  3977.  
  3978. GetEA will allow me to get the value of an extended attribute from
  3979. a file if I know the name of the the attribute.  Is there a way (from
  3980. within a REXX program) that I can determine what extended attributes
  3981. (if any) are associated with a given file?
  3982.  
  3983. Any help would be appreciated.  Thanks in advance
  3984.  
  3985. Erik Vander Ahe
  3986. The Mutual Group
  3987.  
  3988. ----- OS2REXX CFORUM appended at 18:04:16 on 92/07/24 GMT (by IL11901 at OS2CUST)
  3989. Subject: CommandLine 1.1
  3990.  
  3991. Please check out CommandLine 1.1 from Soft & GUI Inc.  CommandLine is a hotkey
  3992. PM based application launcher and command prompt, which in addition to inline
  3993. filename completion and file find and command history has an inline REXX
  3994. expressions interpreter.   CommandLine lists for $39.95
  3995.  
  3996. Soft & GUI Inc
  3997. (718) 769-8017
  3998.  
  3999. Steve Dacek - Soft & GUI Inc
  4000.  
  4001. ----- OS2REXX CFORUM appended at 22:26:04 on 92/07/24 GMT (by USBC238 at OS2CUST)
  4002. Subject: SysDestroyObject
  4003.  
  4004. Using SysCreateObject I created some test WPProgram objects with a
  4005. NODELETE=YES setting to test some desktop security.  Now I really
  4006. want to delete the object (I don't want my users to) and I can't find
  4007. a way to do it.  I tried to use SysDestroyObject <M_TEST>, which is
  4008. the OBJECTID I gave it when it was created and received an Error 35
  4009. running xxx.cmd, line 8: Invalid expression.  REXX Command reference
  4010. has no reference for SysDestroyObject so I don't know if the syntax
  4011. is wrong.  I do have the latest REXX20.ZIP files installed.  Any ideas?
  4012.  
  4013. Charles Boyce - US Bank, Portland OR
  4014.  
  4015. ----- OS2REXX CFORUM appended at 18:29:48 on 92/07/25 GMT (by ROK2027 at OS2CUST)
  4016. Subject: SysCreateObject and Rexx Samples
  4017. Ref: Append at 14:15:49 on 92/07/24 GMT (by MIKELAMB at KGNVMC)
  4018.  
  4019. Mike,
  4020.  
  4021. Thanks for your time/effort and examples.....
  4022.  
  4023. I lost my desktop (again) this week and have now created some rexx procedures
  4024. based on your examples to recreate the CM, ES, UPM and LS folders should I
  4025. have this opportunity in the future.
  4026.  
  4027. This involved sitting down at another system that had just been installed
  4028. and copying down all the various info for these folders (ugh..)
  4029.  
  4030. Is there anyway for me to send them to this bbs/forum so others won't have
  4031. to reinvent the wheel...?
  4032.  
  4033. Lionel Dyck - Rockwell International, Information Systems Center
  4034.  
  4035. ----- OS2REXX CFORUM appended at 11:59:55 on 92/07/27 GMT (by XXCDSX26 at TORVMCOP)
  4036. Subject: SysDestroyObject
  4037. Ref:     Append at 22:26:04 on 92/07/24 GMT (by USBC238 at OS2CUST)
  4038.  
  4039. Charles:
  4040.  
  4041. Try moving the object to Drive A: (with a disk in it).
  4042.  
  4043. Michael Harper - Cdn Depository for Securities, Ltd
  4044.  
  4045. ----- OS2REXX CFORUM appended at 12:33:26 on 92/07/27 GMT (by CONT00 at LEXVMK)
  4046. ..... OS2REXX CFORUM modified at 12:53:13 on 92/07/27 GMT (by CONT00 at LEXVMK)
  4047. Subject: SysDestroyObject
  4048. Ref:     Append at 22:26:04 on 92/07/24 GMT (by USBC238 at OS2CUST)
  4049.  
  4050. Ahmmmm... How does the call look like ? Some apostrophe missing ?
  4051. This kind of error is NOT related to SysDestroyObject !
  4052.  
  4053. Gregory Czaja, Lexington 8-545-3311  1992/07/27  08:32
  4054.  
  4055. ----- OS2REXX CFORUM appended at 12:46:42 on 92/07/27 GMT (by MCGUIRE at GDLVM7)
  4056. Subject: SysDestroyObject
  4057. Ref:     Append at 22:26:04 on 92/07/24 GMT (by USBC238 at OS2CUST)
  4058.  
  4059. Error 35 is a syntax error before you even called the SysDestroyObject
  4060. function.  If you actually coded it the way you showed, add quotes around the
  4061. object name:
  4062.  
  4063.    call SysDestroyObject '<M_TEST>'
  4064.  
  4065. Rick McGuire - SAA Rexx Development, Endicott
  4066.  
  4067. ----- OS2REXX CFORUM appended at 15:24:00 on 92/07/27 GMT (by USBC238 at OS2CUST)
  4068. Subject: SysDestroyObject
  4069. Ref: Append at 12:33:26 on 92/07/27 GMT (by CONT00 at LEXVMK)
  4070.  
  4071. Yes, it was a problem of missing quotes... however, now the command runs with
  4072. out errors, but the object stays on the desktop.
  4073.  
  4074. Here is the the file:
  4075.  
  4076. /* Destroy.cmd */
  4077.  
  4078. call rxfuncadd sysloadfuncs, rexxutil, sysloadfuncs
  4079. call sysloadfuncs
  4080.  
  4081. call SysDestroyObject'<M_TEST>'
  4082.  
  4083. Here is the file I used to create the object:
  4084.  
  4085. /* Refrnce.cmd */
  4086.  
  4087. call rxfuncadd sysloadfuncs, rexxutil, sysloadfuncs
  4088. call sysloadfuncs
  4089.  
  4090. classname='Mindex'
  4091. title='Test Help Index'
  4092. location='<WP_DESKTOP>'
  4093. setup='INDEX=HELP;OBJECTID=<M_TEST>;NODELETE=YES'
  4094. call BldObj
  4095.  
  4096. /* Build Object */
  4097. call charout , 'Building: 'Title
  4098. result = SysCreateObject(classname, title, location, setup)
  4099. if result =1 then call charout , '... Object created'
  4100. else call charout, '... Not created, return code ='result
  4101. return
  4102.  
  4103. Charles Boyce - US Bank, Portland OR
  4104.  
  4105. ----- OS2REXX CFORUM appended at 16:53:02 on 92/07/27 GMT (by CONT00 at LEXVMK)
  4106. Subject: SysDestroyObject
  4107. Ref:     Append at 15:24:00 on 92/07/27 GMT (by USBC238 at OS2CUST)
  4108.  
  4109. I've run your very program and it DID delete the created object !
  4110.  
  4111. One hint: my REXXUTIL.DLL is dated 7/23/1992... don't remember which
  4112. version is required to support SysDestroyObject.
  4113.  
  4114. Gregory Czaja, Lexington 8-545-3311  1992/07/27  12:48
  4115.  
  4116. ----- OS2REXX CFORUM appended at 18:02:40 on 92/07/27 GMT (by MCGUIRE at GDLVM7)
  4117. Subject: SysDestroyObject
  4118. Ref:     Append at 15:24:00 on 92/07/27 GMT (by USBC238 at OS2CUST)
  4119.  
  4120. Not sure what to tell you.  I just tried many different variations of what you
  4121. did and the object was successfully removed each time...except for the one
  4122. time I forgot to include the objectid!
  4123.  
  4124. Rick McGuire - SAA Rexx Development, Endicott
  4125.  
  4126. ----- OS2REXX CFORUM appended at 15:30:47 on 92/07/28 GMT (by USBC238 at OS2CUST)
  4127. Subject: SysDestroyObject
  4128. Ref: Append at 16:53:02 on 92/07/27 GMT (by CONT00 at LEXVMK)
  4129.  
  4130. OK, now I am rather perplexed, I have tried to run the destroy
  4131. program again, it runs with no error message, but the object remains
  4132. on the desktop.  I tried to run the create program, and it fails
  4133. because the object id already exists (I assume) so I think I am using
  4134. the correct object id in the destroy program.  If I try to move the
  4135. object to the a: drive icon I get a minus sign -no can do-.  I am
  4136. using the rexx fixes from this bbs and my rexxutil.dll is dated
  4137. 07-01-92 4:29p with a size of 31321 bytes. The REXX20.ZIP is 07-15-92
  4138. size of 175065 bytes. Now, 1)Is there a way to query the system to
  4139. find all object ids?  2) How do I get the rexxutil.dll with the later
  4140. date?3) Are there any other suggestions?
  4141.  
  4142. Charles Boyce - US Bank, Portland OR
  4143.  
  4144. ----- OS2REXX CFORUM appended at 16:22:54 on 92/07/28 GMT (by MCGUIRE at GDLVM7)
  4145. Subject: SysDestroyObject
  4146. Ref:     Append at 15:30:47 on 92/07/28 GMT (by USBC238 at OS2CUST)
  4147.  
  4148. 1)  The append by Mike Lamb in this forum describing the SysCreateObject
  4149. function includes a program to display all the object ids known to the system.
  4150.  
  4151. 2)  The latest REXXUTIL.DLL is in the REXX20.ZIP file on this BBS.
  4152.  
  4153. Rick McGuire - SAA Rexx Development, Endicott
  4154.  
  4155. ----- OS2REXX CFORUM appended at 20:51:57 on 92/07/28 GMT (by USBC238 at OS2CUST)
  4156. Subject: SysDestroyObject
  4157. Ref: Append at 16:22:54 on 92/07/28 GMT (by MCGUIRE at GDLVM7)
  4158.  
  4159. Thanks Rick, by using Mike's program to display the object ids I
  4160. found that it had an extra character appended to the end (fingers
  4161. flying too fast). I changed the program to reference the correct id
  4162. and it is gone.
  4163.  
  4164. Charles Boyce - US Bank, Portland OR
  4165.  
  4166. ----- OS2REXX CFORUM appended at 14:11:26 on 92/07/29 GMT (by MIKELAMB at KGNVMC)
  4167. Subject: SysCreateObject and Rexx Samples
  4168. Ref:     Append at 14:15:49 on 92/07/24 GMT (by MIKELAMB at KGNVMC)
  4169.  
  4170. New modified append for the REXXUTIL samples. Fixed the problem I caused
  4171. by not including ||'s at the end of my breaking up of the setup strings.
  4172.  
  4173. Also I just had to add a few more items...
  4174.  
  4175. Added information regarding changing some System Settings (added a
  4176. new section after sample Rexx code). Also added warning in REBUILD.CMD
  4177. sample about replacing Folder objects. Also added new sample ICONRES.CMD
  4178. which builds a folder containing many of the OS/2 V2 installed icons
  4179. using system DLL files, is an example of using ICONRESOURCE setup parm.
  4180.  
  4181.               Michael A. Lamb  (MIKELAMB @ KGNVMC)  1992/07/29 10:06 EDT
  4182.  
  4183. ----- OS2REXX CFORUM appended at 14:27:01 on 92/07/29 GMT (by MIKELAMB at KGNVMC)
  4184. Subject: SysCreateObject and Rexx Samples
  4185. Ref:     Append at 18:29:48 on 92/07/25 GMT (by ROK2027 at OS2CUST)
  4186.  
  4187. I've also opened up a question to IBM Support asking them what's the
  4188. "supported" method of recreating these object should someone shred
  4189. them. I tried to look into this and ran into a brick wall as I could
  4190. not find out enough information to rebuild the objects. They are created
  4191. using the older 1.3 Prfxxx calls and are Groups instead of Folder
  4192. objects. I did use the DPRG program from LMU/2 to dump the items and
  4193. you can get a good look at the entries from its output. However to do
  4194. a real good job that was universally useful I'd have to also look at
  4195. the IBMLVL.INI file to find out what was installed and where to really
  4196. recreate the objects. Also the REXXUTILs code does not use any of the
  4197. older Prfxxx calls to build 1.3-like Groups so instead I'd have had to
  4198. make workplace shell folder objects. I was hoping to find a file that
  4199. detailed the entries for ES, UPM, CM, LS, I did find some in *.PIP files
  4200. but not others... Perhaps I'll get an answer from IBM Support...
  4201.  
  4202. I'm not sure how these CFORUM files work, I suppose you could do as
  4203. I did and append them here?
  4204.  
  4205.               Michael A. Lamb  (MIKELAMB @ KGNVMC)  1992/07/29 10:12 EDT
  4206.  
  4207. ----- OS2REXX CFORUM appended at 14:29:27 on 92/07/30 GMT (by ROK2027 at OS2CUST)
  4208. ..... OS2REXX CFORUM modified at 19:38:05 on 92/07/30 GMT (by ROK2027 at OS2CUST)
  4209. Subject: Samples to rebuild (CM, ES, UPM and LAN) folders
  4210. This APPEND was deleted at 15:38:04 on 07/30/92 EST.
  4211.  
  4212. ----- OS2REXX CFORUM appended at 02:31:28 on 92/07/31 GMT (by MCC003 at OS2CUST)
  4213. Subject: CM 3270 font sizes
  4214.  
  4215. Is there is a way to manipulate the 3270 window font sizes with REXX?
  4216.  
  4217. Jim Brunke
  4218.  
  4219. ----- OS2REXX CFORUM appended at 02:33:18 on 92/07/31 GMT (by IL22993 at OS2CUST)
  4220. Subject: Samples to rebuild (CM, ES, UPM and LAN) folders
  4221. Ref: Append at 14:29:27 on 92/07/30 GMT (by ROK2027 at OS2CUST)
  4222.  
  4223. Lionel...
  4224.  
  4225. I take it you are trying to post some REXX code to rebuild the ES folders?
  4226. I am holding my breath... (well not quite) ...  One of our managers who is
  4227. still sticking by OS/2 just wiped out his desktop.   I have him running
  4228. using "CM" from startup.cmd, but I anxiously await some means of rebuilding.
  4229.  
  4230. Good luck!!!  (I am sure others will greatly appreciate your efforts... I sure
  4231. will!)
  4232.  
  4233. George Clark, Norton Company
  4234.  
  4235. ----- OS2REXX CFORUM appended at 14:28:19 on 92/07/31 GMT (by ROK2027 at OS2CUST)
  4236. Subject: Samples to Rebuild CM, ES, LAN and UPM Folders
  4237.  
  4238. I have tried to upload this several times and each time receive the following
  4239. message from my OS/2 Window where the send command is issued:
  4240.  
  4241.   TRANS010  The host has not responded.  Switch to the emulator session.
  4242.  
  4243. When I switch back to my 3270 session I am not sure what to do and the only
  4244. thing that seems to work is the Esc key.  The result seems to be that
  4245. nothing gets uploaded.
  4246.  
  4247. I will send my samples to those who wish them via Internet or IBMMail or to
  4248. CompuServe until I achieve success in uploading.  Perhaps someone can suggest
  4249. something that will work.  My command is/was:
  4250.  
  4251.     send up.txt c:showtemp text a (ascii crlf lrecl 80
  4252.  
  4253. Note:  My file is 273 records and i am reluctant to cut/paste 40+ times
  4254. as I might miss something.
  4255.  
  4256. Lionel Dyck    IBMMAIL: USROKNTN   Internet: lbdyck@osreq48.rockwell.com
  4257.                IBMLink: ROK2027
  4258.  
  4259. Lionel Dyck - Rockwell International, Information Systems Center
  4260.  
  4261. ----- OS2REXX CFORUM appended at 17:45:18 on 92/07/31 GMT (by XXROYT05 at TORVMCOP)
  4262. Subject: REXX & DBM
  4263.  
  4264. I am trying to write some rexx routines which use DSQCIX and DSQSETUP
  4265. but so far I have not been very successful. Does anyone have some
  4266. sample code which they wouldn't mind sharing. Thanks in advance...
  4267.  
  4268. Ralf Mibus - Royal Trustco - Toronto, Canada (416)981-4067
  4269.  
  4270. ----- OS2REXX CFORUM appended at 18:45:09 on 92/07/31 GMT (by NAAO3IY at OS2CUST)
  4271. Subject: Samples to rebuild (CM, ES, UPM and LAN) folders
  4272. Ref: Append at 02:33:18 on 92/07/31 GMT (by IL22993 at OS2CUST)
  4273.  
  4274. In my experience, the ES folders can be recovered by:
  4275.  
  4276.    First, shredding them completely, and
  4277.    Second, doing a null reinstall (REINST, but don't actually add anything).
  4278.  
  4279. It seems that the code gets _very_ confused if the folders already
  4280. exist, but it knows what to do if it can't find them at all.
  4281.  
  4282. John Kennedy -- Hoechst Celanese, Bridgewater, NJ
  4283.  
  4284. ----- OS2REXX CFORUM appended at 15:56:04 on 92/08/01 GMT (by GBFORNEY at WASVMIC5)
  4285. Subject: REXX & DBM
  4286. Ref:     Append at 17:45:18 on 92/07/31 GMT (by XXROYT05 at TORVMCOP)
  4287.  
  4288. Here's something I wrote with DSQCIX. It does some date calculations
  4289. and the starts a QM session, sets some QM variables with the
  4290. calculated date values and then runs a "main" menu called MASTER
  4291. in the LANG1 database.
  4292.  
  4293. /*      Rexx Exec                 Greg Forney        */
  4294. /*      QUERY.CMD                                    */
  4295. /*         Query Manager Interface                   */
  4296. Signal Start      /* Subroutines come first          */
  4297.  
  4298. /*------------------------------------------------------------------
  4299.  * GetRxQM registers the QM interface in memory    
  4300.  *------------------------------------------------------------------*/
  4301. GetRxQM:
  4302. rcy = 0
  4303. If  rxfuncquery('DSQCIX')<>0
  4304.     then rcy=rxfuncadd('DSQCIX','DSQCIX','DSQCIX')
  4305. If  rcy <> 0 then call error "DSQCIX Not Available"
  4306. If  rxfuncquery('DSQSETUP')<>0
  4307.     then rcy=rxfuncadd('DSQSETUP','DSQSETUP','DSQSETUP')
  4308. If  rcy <> 0 then call error "DSQCIX Not Available"
  4309. Return
  4310.  
  4311. /*------------------------------------------------------------------
  4312.  * CheckDSQS exaimines QM interface errors
  4313.  *------------------------------------------------------------------*/
  4314. CheckDSQS:
  4315.         DSQ_result = DSQ_return_code
  4316.         If DSQ_result <> 0  then Do
  4317.            Say "Message Id        = " DSQ_MESSAGE_ID
  4318.            Say " Q Message Id     = " DSQ_Q_MESSAGE_ID
  4319.            Say " Start Parm Error = "DSQ_START_PARM_ERROR
  4320.            End
  4321. return DSQ_result
  4322.  
  4323. /*------------------------------------------------------------------
  4324.  * CalcDays sets a variable for the date which is 4
  4325.  * working days after the current calendar day
  4326.  *------------------------------------------------------------------*/
  4327. CalcDays:
  4328.       /*------------------------------------------------------------
  4329.        * Calculate two days hence in working days
  4330.        *------------------------------------------------------------*/
  4331. today=date('S')
  4332. DayOfWeek=date('B')//7
  4333. year = substr(today,1,4)
  4334. Month = substr(today,5,2)
  4335. day = substr(today,7,2)
  4336. Do DOWplus4.DayOfWeek
  4337.    Day = right(Day + 1,2,0)
  4338.    If Day > DIM.Month Then Do
  4339.       Day = 01
  4340.       Month = right(Month + 1,2,0)
  4341.       IF Month > 12 Then Do
  4342.          Year = Year + 1
  4343.          Month = right(01,2,0)
  4344.          End /* of Month > 12 */
  4345.       End /* of Day > DIM.Month */
  4346.    End /* of DOWplus4.Dayof Week */
  4347. DBDateplus4 = Year║║"-"║║Month║║"-"║║Day
  4348.      /*-------------------------------------------------------------
  4349.       * Calculate two weeks hence in working days
  4350.       *-------------------------------------------------------------*/
  4351. today=date('S')
  4352. DayOfWeek=date('B')//7
  4353. year = substr(today,1,4)
  4354. Month = substr(today,5,2)
  4355. Day = substr(today,7,2)
  4356. Do 14
  4357.    Day = right(Day + 1,2,0)
  4358.    If Day > DIM.Month Then Do
  4359.       Day = 01
  4360.       Month = right(Month + 1,2,0)
  4361.       IF Month > 12 Then Do
  4362.          Year = Year + 1
  4363.          Month = right(01,2,0)
  4364.          End /* of Month > 12 */
  4365.       End /* of Day > DIM.Month */
  4366.    End /* of Do 14 */
  4367. DBDateplus14 = Year║║"-"║║Month║║"-"║║Day
  4368.     /*--------------------------------------------------------------
  4369.      * Calculate two weeks past in working days
  4370.      *--------------------------------------------------------------*/
  4371. today=date('S')
  4372. DayOfWeek=date('B')//7
  4373. year = substr(today,1,4)
  4374. Month = substr(today,5,2)
  4375. Day = substr(today,7,2)
  4376. Do 14
  4377.    Day = right(Day - 1,2,0)
  4378.    If Day = 0 Then Do
  4379.       Month = right(Month - 1,2,0)
  4380.       If Month = 0 Then Do
  4381.          Year = right(year - 1,2,0)
  4382.          Month = 12
  4383.          End /* of Month = 0 */
  4384.       Day = DIM.Month
  4385.       End /* of Day = 0 */
  4386.    End /* of Do 14 */
  4387. DBDateminus14 = Year║║"-"║║Month║║"-"║║Day
  4388. return
  4389.  
  4390. /*------------------------------------------------------------------
  4391.  * Initialize        
  4392.  *------------------------------------------------------------------*/
  4393. Initialize:
  4394. DOWplus4.=0
  4395. DOWplus4.0=4 /* 0 is Monday */
  4396. DOWplus4.1=6
  4397. DOWplus4.2=6
  4398. DOWplus4.3=6
  4399. DOWplus4.4=6
  4400. DOWplus4.5=6
  4401. DOWplus4.6=5
  4402. DIM.=0
  4403. daysofMonth = 31 28 31 30 31 30 31 31 30 31 30 31
  4404. Do i = 01 to 12
  4405.    If i < 10 Then i = right(i,2,0)
  4406.    parse var daysofmonth DIM.i daysofmonth
  4407.    End
  4408. Year=substr(date('S'),1,4)
  4409. If Year//4 = 0 Then DIM.2 = 29
  4410. Return
  4411.  
  4412. Error:
  4413. arg msg
  4414. Say "SOme error happened on Line " sigl
  4415. Say "Query.CMD Error: " msg
  4416. SIgnal Quit
  4417.  
  4418. Quit:
  4419. Exit
  4420.  
  4421. /*  ************************************************** */
  4422. /*                               Main Program          */
  4423. /*  ************************************************** */
  4424. Start:
  4425. Signal On Error
  4426.  
  4427. Call Initialize
  4428.  
  4429. Call CalcDays
  4430.  
  4431. /* Get Rexx QM API's*/
  4432. Call GetRxQM
  4433.  
  4434. Call DSQCIX 'START','DSQSMODE="INTERACTIVE"','DSQSDBNM = "LANG1"'
  4435. rcy = CheckDSQS()
  4436. Call DSQCIX 'SET GLOBAL','DatePlus4=DBdateplus4'
  4437. rcy = CheckDSQS()
  4438. Call DSQCIX 'SET GLOBAL','DatePlus14=DBdateplus14'
  4439. rcy = CheckDSQS()
  4440. Call DSQCIX 'SET GLOBAL','Dateminus14=DBdateminus14'
  4441. rcy = CheckDSQS()
  4442.  
  4443. Call DSQCIX 'RUN MENU MASTER'
  4444. rcy = CheckDSQS()
  4445. Call DSQCIX 'EXIT'
  4446. rcy = CheckDSQS()
  4447. Call Quit
  4448.  
  4449. Greg Forney - DVSC
  4450.  
  4451. ----- OS2REXX CFORUM appended at 01:51:27 on 92/08/02 GMT (by MIKELAMB at KGNVMC)
  4452. Subject: Samples to Rebuild CM, ES, LAN and UPM Folders
  4453. Ref:     Append at 14:28:19 on 92/07/31 GMT (by ROK2027 at OS2CUST)
  4454.  
  4455. Try setting your file transfer buffer size for that host session to 2.
  4456.  
  4457.               Michael A. Lamb  (MIKELAMB @ KGNVMC)  1992/08/01 21:50 EDT
  4458.  
  4459. ----- OS2REXX CFORUM appended at 09:31:35 on 92/08/03 GMT (by VERSTEEG at UITVM1)
  4460. Subject: REXX & DBM
  4461. Ref:     Append at 17:45:18 on 92/07/31 GMT (by XXROYT05 at TORVMCOP)
  4462.  
  4463. Here is a second sample. Note the first line that registers
  4464. REXX/QM variables.
  4465. In this sample query Q1300 does a select * from a nonexisting table.
  4466.  
  4467. /*  retrieve DSQSQLEC in case of error QRW1300 */
  4468. '@DSQRGSTR'
  4469. call DSQCIX 'START','DSQSMODE=INTERACTIVE','DSQSDBNM="SAMPLE"'
  4470. call DSQCIX 'RUN QUERY Q1300' /* generate SQL0204 */
  4471. call dsqcix 'get current','xyz=DSQSQLEC'
  4472. say xyz    /* this will produce: -204 */
  4473. call DSQCIX 'EXIT'
  4474. exit
  4475.  
  4476. Anton Versteeg - ESAT PWS CoC Uithoorn, NL       *** GO OS/2 2.0 ***
  4477.  
  4478. ----- OS2REXX CFORUM appended at 15:01:54 on 92/08/06 GMT (by XXROYT05 at TORVMCOP)
  4479. Subject: REXX & DBM
  4480. Ref:     Append at 09:31:35 on 92/08/03 GMT (by VERSTEEG at UITVM1)
  4481.  
  4482. Thanks for the samples...much appreciated!
  4483.  
  4484. Ralf Mibus - Royal Trustco - Toronto, Canada (416)981-4067
  4485.  
  4486. ----- OS2REXX CFORUM appended at 22:43:58 on 92/08/06 GMT (by ROK2027 at OS2CUST)
  4487. Subject: Samples to Rebuild CM, ES, LAN and UPM Folders
  4488.  
  4489. Here are 4 REXX applications to rebuild Desktop folders after an
  4490. ALT-F1 for Lan Requestor, Communications Manager, Extended Services
  4491. and User Profile Management.  I have only included in each folder
  4492. those specific objects that I needed, but this is a good start if
  4493. you want the rest.  It just takes time to copy down the information
  4494. from a 'clean' system and then walk back to your workstation and
  4495. enter the appropriate commands for the rebuild.  This simplifies
  4496. that.
  4497. Thanks to Mike Lamb of IBM for his examples and documentation.
  4498. Each .cmd file is delimited by >> file.CMD <<
  4499. @
  4500. >> BUILDCM.CMD <<
  4501. @
  4502. /* BUILDCM.CMD: Rebuild CM Folder after Alt-F1                          */
  4503. /* modified by Lionel Dyck, Rockwell International                      */
  4504. /* FOLDER.CMD: Sample code using REXXUTIL's SysCreateObject function    */
  4505. /* Builds a folder on the DeskTop and places some program objects in it.*/
  4506. /* Mike Lamb: MIKELAMB/KGNVMC                                           */
  4507. @
  4508. /* Load REXXUTIL */
  4509. call rxfuncadd sysloadfuncs, rexxutil, sysloadfuncs
  4510. call sysloadfuncs
  4511. @
  4512. /*The basic call is listed next.                                           */
  4513. /*rc=SysCreateObject(classname, title, location <,setup>, <,duplicateflag>)*/
  4514. @
  4515. call SysCls
  4516. Say '';Say 'Using REXXUTILs to Add a Communications Manager Folder and Program
  4517. O
  4518. bjects...'
  4519. @
  4520. /* All of the routines pass parameters to a subroutine to perform the call */
  4521. @
  4522. classname='WPFolder'
  4523. title='Communications Manager'
  4524. location='<WP_DESKTOP>'
  4525. setup='OBJECTID=<CM>'
  4526. Call BldObj
  4527. @
  4528. Say "Folder Build Complete - starting build of Program Entries"
  4529. @
  4530. classname='WPProgram'
  4531. title='Communications Manager'
  4532. location='<CM>'
  4533. setup='OBJECTID=<CM_CON>;',
  4534.     ||'EXENAME=C:\CMLIB\STARTCM.CMD;',
  4535.     ||'STARTUPDIR=C:\CMLIB;',
  4536.     ||'PROGTYPE=FULLSCREEN;'
  4537. Call BldObj
  4538. @
  4539. Say "Add of Communications Manager Folder is now complete....."
  4540. @
  4541. Exit
  4542. @
  4543. /* Build Object */
  4544. BldObj:
  4545. call charout ,'Building: 'title
  4546. @
  4547. /* Build object using REPLACE as duplicateflag */
  4548. result = SysCreateObject(classname, title, location, setup, 'R')
  4549. @
  4550. If result=1 Then call charout ,'...   Object created!'
  4551. Else             call charout ,'...   Not created! Return code='result
  4552. @
  4553. Say '';
  4554. Return
  4555. @
  4556. >> BUILDES.CMD <<
  4557. @
  4558. /* BUILDES.CMD: Rebuild ES Folder after Alt-F1                          */
  4559. /* modified by Lionel Dyck, Rockwell International                      */
  4560. /* FOLDER.CMD: Sample code using REXXUTIL's SysCreateObject function    */
  4561. /* Builds a folder on the DeskTop and places some program objects in it.*/
  4562. /* Mike Lamb: MIKELAMB/KGNVMC                                           */
  4563. @
  4564. /* Load REXXUTIL */
  4565. call rxfuncadd sysloadfuncs, rexxutil, sysloadfuncs
  4566. call sysloadfuncs
  4567. @
  4568. /*The basic call is listed next.                                           */
  4569. /*rc=SysCreateObject(classname, title, location <,setup>, <,duplicateflag>)*/
  4570. @
  4571. call SysCls
  4572. Say '';Say 'Using REXXUTILs to Add a Extended Services Folder and Program
  4573. Object
  4574. s...'
  4575. @
  4576. /* All of the routines pass parameters to a subroutine to perform the call */
  4577. @
  4578. classname='WPFolder'
  4579. title='Extended Services'
  4580. location='<WP_DESKTOP>'
  4581. setup='OBJECTID=<ES>'
  4582. Call BldObj
  4583. @
  4584. Say "Folder Build Complete - starting build of Program Entries"
  4585. @
  4586. classname='WPProgram'
  4587. title='Basic Configuration and Installation'
  4588. location='<ES>'
  4589. setup='OBJECTID=<ES_CON>;',
  4590.     ||'EXENAME=C:\OS2\INSTALL\ESCFG.CMD;',
  4591.     ||'STARTUPDIR=C:\OS2\INSTALL;',
  4592.     ||'PROGTYPE=FULLSCREEN;'
  4593. Call BldObj
  4594. @
  4595. classname='WPProgram'
  4596. title='Add or Remove Features'
  4597. location='<ES>'
  4598. setup='OBJECTID=<ES_RECON>;',
  4599.     ||'EXENAME=C:\OS2\INSTALL\REINST.CMD;',
  4600.     ||'STARTUPDIR=C:\OS2\INSTALL;',
  4601.     ||'PROGTYPE=FULLSCREEN;'
  4602. Call BldObj
  4603. @
  4604. Say "Add of Extended Services Folder is now complete....."
  4605. @
  4606. Exit
  4607. @
  4608. /* Build Object */
  4609. BldObj:
  4610. call charout ,'Building: 'title
  4611. @
  4612. /* Build object using REPLACE as duplicateflag */
  4613. result = SysCreateObject(classname, title, location, setup, 'R')
  4614. @
  4615. If result=1 Then call charout ,'...   Object created!'
  4616. Else             call charout ,'...   Not created! Return code='result
  4617. @
  4618. Say '';
  4619. Return
  4620. @
  4621. >> BUILDLAN.CMD <<
  4622. @
  4623. /* BUILDLAN.CMD: Rebuild LAN Folder after Alt-F1                        */
  4624. /* modified by Lionel Dyck, Rockwell International                      */
  4625. /* FOLDER.CMD: Sample code using REXXUTIL's SysCreateObject function    */
  4626. /* Builds a folder on the DeskTop and places some program objects in it.*/
  4627. /* Mike Lamb: MIKELAMB/KGNVMC                                           */
  4628. @
  4629. /* Load REXXUTIL */
  4630. call rxfuncadd sysloadfuncs, rexxutil, sysloadfuncs
  4631. call sysloadfuncs
  4632. @
  4633. /*The basic call is listed next.                                           */
  4634. /*rc=SysCreateObject(classname, title, location <,setup>, <,duplicateflag>)*/
  4635. @
  4636. call SysCls
  4637. Say '';Say 'Using REXXUTILs to Add a LAN Services Folder and Program
  4638. Objects...'
  4639. @
  4640. /* All of the routines pass parameters to a subroutine to perform the call */
  4641. @
  4642. classname='WPFolder'
  4643. title='LAN Services'
  4644. location='<WP_DESKTOP>'
  4645. setup='OBJECTID=<LAN_SERV>'
  4646. Call BldObj
  4647. @
  4648. Say "Folder Build Complete - starting build of Program Entries"
  4649. @
  4650. classname='WPProgram'
  4651. title='LAN Messaging'
  4652. location='<LAN_SERV>'
  4653. setup='OBJECTID=<LAN_MSG>;',
  4654.     ||'EXENAME=C:\IBMLAN\NETPROG\NETSEND.EXE;',
  4655.     ||'STARTUPDIR=C:\IBMLAN\NETPROG;',
  4656.     ||'PROGTYPE=FULLSCREEN;'
  4657. Call BldObj
  4658. @
  4659. classname='WPProgram'
  4660. title='LAN Requester'
  4661. location='<LAN_SERV>'
  4662. setup='OBJECTID=<LAN_REQ>;',
  4663.     ||'EXENAME=C:\IBMLAN\NETPROG\NET.EXE;',
  4664.     ||'STARTUPDIR=C:\IBMLAN\NETPROG;',
  4665.     ||'PROGTYPE=FULLSCREEN;'
  4666. Call BldObj
  4667. @
  4668. classname='WPProgram'
  4669. title='LAN Services Installation and Configuration'
  4670. location='<LAN_SERV>'
  4671. setup='OBJECTID=<LAN_INST>;',
  4672.     ||'EXENAME=C:\IBMLAN\INSTALL\LANINST.EXE;',
  4673.     ||'STARTUPDIR=C:\IBMLAN\INSTALL;',
  4674.     ||'PROGTYPE=PM;'
  4675. Call BldObj
  4676. @
  4677. Say "Add of LAN Services Folder is now complete....."
  4678. @
  4679. Exit
  4680. @
  4681. /* Build Object */
  4682. BldObj:
  4683. call charout ,'Building: 'title
  4684. @
  4685. /* Build object using REPLACE as duplicateflag */
  4686. result = SysCreateObject(classname, title, location, setup, 'R')
  4687. @
  4688. If result=1 Then call charout ,'...   Object created!'
  4689. Else             call charout ,'...   Not created! Return code='result
  4690. @
  4691. Say '';
  4692. Return
  4693. @
  4694. >> BUILDUPM.CMD <<
  4695. @
  4696. /* BUILDUPM.CMD: Rebuild UP_MGMT Folder after Alt-F1                */
  4697. /* modified by Lionel Dyck, Rockwell International                      */
  4698. /* FOLDER.CMD: Sample code using REXXUTIL's SysCreateObject function    */
  4699. /* Builds a folder on the DeskTop and places some program objects in it.*/
  4700. /* Mike Lamb: MIKELAMB/KGNVMC                                           */
  4701. @
  4702. /* Load REXXUTIL */
  4703. call rxfuncadd sysloadfuncs, rexxutil, sysloadfuncs
  4704. call sysloadfuncs
  4705. @
  4706. /*The basic call is listed next.                                           */
  4707. /*rc=SysCreateObject(classname, title, location <,setup>, <,duplicateflag>)*/
  4708. @
  4709. call SysCls
  4710. Say '';Say 'Using REXXUTILs to Add a User Profile Management Folder and Program
  4711. Objects...'
  4712. @
  4713. /* All of the routines pass parameters to a subroutine to perform the call */
  4714. @
  4715. classname='WPFolder'
  4716. title='User Profile Management'
  4717. location='<WP_DESKTOP>'
  4718. setup='OBJECTID=<UP_MGMT>'
  4719. Call BldObj
  4720. @
  4721. Say "Folder Build Complete - starting build of Program Entries"
  4722. @
  4723. classname='WPProgram'
  4724. title='Logoff'
  4725. location='<UP_MGMT>'
  4726. setup='OBJECTID=<LOGOFF>;',
  4727.     ||'EXENAME=C:\MUGLIB\LOGOFF.EXE;',
  4728.     ||'PARAMETERS=/L;',
  4729.     ||'STARTUPDIR=C:\MUGLIB;',
  4730.     ||'PROGTYPE=PM;'
  4731. Call BldObj
  4732. @
  4733. classname='WPProgram'
  4734. title='Logon'
  4735. location='<UP_MGMT>'
  4736. setup='OBJECTID=<LOGON>;',
  4737.     ||'EXENAME=C:\MUGLIB\LOGON.EXE;',
  4738.     ||'STARTUPDIR=C:\MUGLIB;',
  4739.     ||'PROGTYPE=PM;'
  4740. Call BldObj
  4741. @
  4742. classname='WPProgram'
  4743. title='User Profile Management'
  4744. location='<UP_MGMT>'
  4745. setup='OBJECTID=<UPM_ACCT>;',
  4746.     ||'EXENAME=C:\MUGLIB\UP_MGMTACCTS.EXE;',
  4747.     ||'STARTUPDIR=C:\MUGLIB;',
  4748.     ||'PROGTYPE=PM;'
  4749. Call BldObj
  4750. @
  4751. Say "Add of User Profile Management Folder is now complete....."
  4752. @
  4753. Exit
  4754. @
  4755. /* Build Object */
  4756. BldObj:
  4757. call charout ,'Building: 'title
  4758. @
  4759. /* Build object using REPLACE as duplicateflag */
  4760. result = SysCreateObject(classname, title, location, setup, 'R')
  4761. @
  4762. If result=1 Then call charout ,'...   Object created!'
  4763. Else             call charout ,'...   Not created! Return code='result
  4764. @
  4765. Say '';
  4766. Return
  4767.  
  4768. Lionel Dyck - Rockwell International, Information Systems Center
  4769.  
  4770. ----- OS2REXX CFORUM appended at 02:15:48 on 92/08/07 GMT (by JL07784 at YMTVM8)
  4771. Subject: How to check the Diskette drive status, ready or not ready ?
  4772.  
  4773. I want to check the diskette drive status in REXX program without
  4774. special program or utilities. I don't want to display OS/2 critical error
  4775. handler screen. So I need to check the diskette was inserted into
  4776. drive or not.
  4777.  I know the stream command as;
  4778.    stream('A:','S')
  4779.  but it returns NULL strings (OS/2 J1.32) and 'UNKNOWN' (OS/2 J2.0).
  4780.  And I tried as;
  4781.    stream('A:\test.dat','C','QUERY EXISTS')
  4782. returns NULL after critical error handler screen (OS/2 J.132) and
  4783. NULL without critical error handler (OS/2 J2.0). Unfortunately,
  4784. this product will be used both OS/2 J1.3 and OS/2 J2.0.
  4785. Please tell me the correct way !
  4786. Thank you advance.
  4787.  
  4788. Solution Platform Development
  4789. Yamato Laboratory, Japan
  4790. M. Yamamoto
  4791.  
  4792. ----- OS2REXX CFORUM appended at 12:47:45 on 92/08/10 GMT (by UDSS013 at OS2CUST)
  4793. Subject: Samples to Rebuild CM, ES, LAN and UPM Folders
  4794.  
  4795. |                                                                            |
  4796. |    TRANS010  The host has not responded.  Switch to the emulator session.  |
  4797. |                                                                            |
  4798.  
  4799. This usually means that the VTAM LOGMODE that you used to connect to IBMLink
  4800. isn't capable of file transfer.  Specifically, the query bit must be on in
  4801. the logmode table (PSERVIC).  The first two bytes of PSERVIC must be 0280.
  4802.  
  4803. You host network support folks should be able to supply you with a logmode
  4804. that will enable file transfer.
  4805.  
  4806. Gary Murphy
  4807.  
  4808. ----- OS2REXX CFORUM appended at 14:04:02 on 92/08/10 GMT (by MIKELAMB at KGNVMC)
  4809. Subject: Samples to Rebuild CM, ES, LAN and UPM Folders
  4810. Ref:     Append at 22:43:58 on 92/08/06 GMT (by ROK2027 at OS2CUST)
  4811.  
  4812. Before anyone goes and used Lionel's code to rebuild objects please
  4813. remember that the code has hardcoded locations for programs "C:" for
  4814. instance for some objects. However since things like LS can be installed
  4815. to other drives you might have to "tweak" with the code to get it
  4816. to build the objects you require. To make the code more robust it could
  4817. look at the \IBMLVL.INI file to determine the location of the products,
  4818. or optionally the PATH statement.
  4819.  
  4820.               Michael A. Lamb  (MIKELAMB @ KGNVMC)  1992/08/10 09:48 EDT
  4821.  
  4822. ----- OS2REXX CFORUM appended at 14:40:43 on 92/08/10 GMT (by MRTOM at YKTVMV)
  4823. Subject: How to check the Diskette drive status, ready or not ready ?
  4824. Ref:     Append at 02:15:48 on 92/08/07 GMT (by JL07784 at YMTVM8)
  4825.  
  4826. Use SysDriveInfo in REXXUTIL.  If the returned value is '', there's
  4827. no disk in the drive.
  4828.  
  4829. Tom
  4830.  
  4831. ----- OS2REXX CFORUM appended at 00:17:12 on 92/08/11 GMT (by IL59746 at OS2CUST)
  4832. Subject: Controlling OS/2 & Workplace Shell from REXX
  4833.  
  4834. I am trying to write a REXX exec to automate some our systems
  4835. performace charting.  As a part of this automation I have a need to
  4836. controll the Comm Manager Emulators.  I need to enable my program to
  4837. log into a VM host, check the reader, receive any files, and download
  4838. (receive) them to the PC.  It is my understanding that REXX can
  4839. control any part of OS/2 and any program running under it.  I would
  4840. need some material that shows how.  Also I would need some references
  4841. to for the Comm Manager where I could look up the calls REXX can make
  4842. to controll the sessions.
  4843.  
  4844. I also got the impression that I can controll DOS & Windows programms
  4845. running under OS/2 using REXX, so I'm looking for any tutorial's or
  4846. references available on this subject as well.  If anyone out there
  4847. has any experience with something similar, I would very much like to
  4848. talk to you.  I am new to REXX, & OS/2, and I am under pressure from
  4849. my management to get this done fast (aren't we all).
  4850.   At this point I'm not even sure that what I'm trying to do is
  4851. possible.  Any advice or help would be greatly appreciated.  Thank you.
  4852.  
  4853. ----- OS2REXX CFORUM appended at 01:17:14 on 92/08/11 GMT (by CNADLER at WMAVM1)
  4854. Subject: Controlling OS/2 & Workplace Shell from REXX
  4855. Ref:     Append at 00:17:12 on 92/08/11 GMT (by IL59746 at OS2CUST)
  4856.  
  4857. What you want for host control is the RXHLLAPI.DOC that is in your
  4858. \CMLIB directory after you REINST  Extended Services with the API
  4859. header functions. The full EHLLAPI reference is available as a
  4860. separate publication fo rfull details on that interface (the RXHLLAPI
  4861. file just taks about the REXX-EHLLAPI interface).
  4862.  
  4863. Cliff Nadler                                         GO TEAM OS/2!
  4864. Systems Integration and Services                     Rockville, MD
  4865. IBM Federal Systems Company                PROFS: NADLER at WMAVM7
  4866.  
  4867. ----- OS2REXX CFORUM appended at 16:48:07 on 92/08/13 GMT (by XXROYT05 at TORVMCOP)
  4868. Subject: Multi-threaded operation
  4869.  
  4870. I have written several routines which download files from the host
  4871. and then update DBM. In an effort to reduce the overall time req'd,
  4872. I would like to begin downloading the next file while DBM is being
  4873. updated by the previous file. In this fashion, very little time will
  4874. be waisted waiting for one process to finish before the next one
  4875. begins. Is this possible with REXX? If so, can anyone provide sample
  4876. code which I could use as a reference? Many thanks...
  4877.  
  4878. Ralf Mibus - Royal Trustco - Toronto, Canada (416)981-4067
  4879.  
  4880. ----- OS2REXX CFORUM appended at 17:27:08 on 92/08/13 GMT (by GBFORNEY at WASVMIC5)
  4881. Subject: Multi-threaded operation
  4882. Ref:     Append at 16:48:07 on 92/08/13 GMT (by XXROYT05 at TORVMCOP)
  4883.  
  4884. Quick and dirty: You should separate the download and update
  4885. code. Each update can be STARTed from the download program at
  4886. the appropriate time:
  4887.  
  4888. /* Example DownLoad Prgm */
  4889. Call DownLoad('data_1')
  4890. "START C:\MYDBAPPS\MYUPDATE.CMD data_1"
  4891. Call Download('data_2')
  4892. etc........
  4893.  
  4894. Greg Forney  bigred@vnet.ibm.com
  4895.  
  4896. ----- OS2REXX CFORUM appended at 20:24:10 on 92/08/13 GMT (by SAMI3QU at OS2CUST)
  4897. Subject: REXX futures
  4898.  
  4899. Rick McGuire,
  4900.  
  4901. I saw the REXX FTN today and have a couple of questions.
  4902.  
  4903. 1) In your presentation you said it would be a couple of years before all the
  4904.    PM, object-oriented, WYSIWYG stuff became available.  Will individual
  4905.    enhancements be made available when they are complete, or will we have to
  4906.    wait for the entire package?  Can you release some sort of schedule for
  4907.    these enhancements?
  4908.  
  4909. 2) REXX under OS/2 seems to be deviating from it's VM and MVS counterparts.
  4910.    I know of at least one function (INDEX) that is not implemented in OS/2
  4911.    REXX.  I know we have the POS function, but this is still a discrepency.
  4912.    We also have the various I/O functions (LINEIN, LINEOUT, etc.) that are
  4913.    implemented as built-in functions instead of operating-system extensions.
  4914.    What direction is REXX taking in terms of consistency between the various
  4915.    implementations?  I know that the differences in the OS's dictate what can
  4916.    or can't be done to a large degree, but I would think that the concept of
  4917.    a common REXX base with operating-system extensions (for I/O and such)
  4918.    presents a more consistent look and feel.
  4919.  
  4920. Thanks for any info.
  4921.  
  4922. Mark Thompson - Coal Services Corp.  St. Louis, MO
  4923.  
  4924. ----- OS2REXX CFORUM appended at 21:25:50 on 92/08/13 GMT (by IL22868 at OS2CUST)
  4925. ..... OS2REXX CFORUM modified at 21:38:56 on 92/08/13 GMT (by IL22868 at OS2CUST)
  4926. Subject: Multi-threaded operation
  4927. This APPEND was deleted at 17:38:55 on 08/13/92 EST.
  4928.  
  4929. ----- OS2REXX CFORUM appended at 00:11:19 on 92/08/14 GMT (by UDSS013 at OS2CUST)
  4930. Subject: Controlling OS/2 & Workplace Shell from REXX
  4931.  
  4932. |  (receive) them to the PC.  It is my understanding that REXX can           |
  4933. |  control any part of OS/2 and any program running under it.  I would       |
  4934. |  need some material that shows how.  Also I would need some references     |
  4935.  
  4936. I have written a program that uses HLLAPI from REXX to login to this OS2BBS
  4937. and download either all of the notes or the just the new notes and place
  4938. them in a file on the OS/2 workstation.   Feel free to use this as sample
  4939. code for your application.  The file can be retrieved on the Hilbert
  4940. Computing BBS at (913) 829-2450 -- 9600 bps 8N1.    If you have any questions,
  4941. you can leave them to Gary Murphy on that board and I will answer them.  The
  4942. file is called OS2BBS.ZIP.
  4943.  
  4944. Others who wish to download and use this (unsupported) code, feel free.
  4945.  
  4946. Gary "This was composed with an offline reader/writer" Murphy
  4947.  
  4948. (Apologies to Wayne Holmes)
  4949.  
  4950. Gary Murphy
  4951.  
  4952. ----- OS2REXX CFORUM appended at 00:14:55 on 92/08/14 GMT (by GPRICHAR at LSAVMIC1)
  4953. Subject: Multi-threaded operation
  4954. Ref:     Append at 16:48:07 on 92/08/13 GMT (by XXROYT05 at TORVMCOP)
  4955.  
  4956. I've written routines that 'overlap' upload (in my case) with a PC-
  4957. based extract. File 1 is extracted then uploaded while file 2 is being
  4958. extracted, etc.I have three REXX procedures, SCHEDULR, CONVERT, &
  4959. UPLOAD. SCHEDULR has two important associated arrays for filename and
  4960. file status. Each of the elements is initialized as follows:
  4961.  
  4962. filename.1='c:\path\file.one'
  4963. filename.2='c:\path\file.two' ... up to filename.10 in my case.
  4964.  
  4965. fstatus.='!CNV' /* so all elememnts have this value */
  4966.  
  4967. Code meanings: !CNV -> not converted yet
  4968.                CCCC -> being converted
  4969.                CNVD -> converted
  4970.                UUUU -> uploading
  4971.                UPLD -> uploaded, done!
  4972.  
  4973. Other variables:
  4974.  
  4975. CONVERTING='NONE'
  4976. UPLOADING='NONE'
  4977. UPLD_CNT=0
  4978.  
  4979. Procedure outline:
  4980.  
  4981. RC=REXXQUE('create','SCHEDQ')
  4982. RC=REXXQUE('set',   'SCHEDQ')
  4983. Do until UPLD_CNT=10
  4984.    if CONVERTING='NONE' | UPLOADING='NONE' then /*ready for some work */
  4985.       rc=CHECK_STATUS()
  4986.    rc=print_status()
  4987.    msg=LINEIN('QUEUE:')/* SCHEDULR will wait here for Q input */
  4988. say 'Q msg received: ' msg
  4989.    parse var msg newstatus fileno
  4990.    if newstatus='UPLD' then
  4991.       do
  4992.          upld_cnt=upld_cnt+1
  4993.          uploading='NONE'
  4994.          fstatus.fileno=newstatus
  4995.       end
  4996.    else
  4997.    if newstatus='CNVD' then
  4998.       do
  4999.          converting='NONE'
  5000.          fstatus.fileno=newstatus
  5001.       end
  5002. end
  5003. rc=REXXQUEUE('Delete','SCHEDQ')
  5004. exit 0
  5005.  
  5006. CHECK_STATUS:
  5007.  
  5008. do fi = 1 to 10
  5009.    if fstatus.fi = '!CNV' then      /* file needs converting? */
  5010.       DO                            /*    yes!                */
  5011.          if converting='NONE' then  /* CONVERT.CMD active?    */
  5012.             do                      /*   No!                  */
  5013.               'start /FS /B /C /MIN convert.cmd parms'
  5014.                fstatus.fi='CCCC'
  5015.                converting=fstatus.fi
  5016.                if uploading <> 'NONE' then  /* UPLOAD.CMD active? */
  5017.                leave                        /*  yes, check queue  */
  5018.             end/*  no, check next file */
  5019.       end
  5020.    else
  5021.    if fstatus.fi = 'CNVD' then
  5022.       DO
  5023.          if uploading='NONE' then
  5024.             do
  5025.               'start /FS /B /C /MIN upload.cmd parms'
  5026.                uploading=filename.fi
  5027.                fstatus.fi='UUUU'
  5028.                if converting <> 'NONE' then
  5029.                   leave
  5030.             end
  5031.       end
  5032. end
  5033. return 0
  5034.  
  5035. PRINT_STATUS:
  5036.  
  5037. /* whatever format you want - I show each filenames and status */
  5038. /* as well as CONVERTING and UPLOADING */
  5039. return 0
  5040.  
  5041. The procs UPLOAD.CMD & CONVERT.CMD have the following structure:
  5042.  
  5043. arg file fileno ...... /* whatever info you need from SCHEDULR */
  5044.  
  5045. /*
  5046.  
  5047. DO YOUR PROCESSING HERE
  5048.  
  5049. */
  5050.  
  5051. rc=REXXQUEUE('set','SCHEDQ')
  5052. queue 'xxxx' fileno      /* xxxx='UPLD' for UPLOAD.CMD  */
  5053.                         /*       'CNVD' for CONVERT.CMD */
  5054. exit 0
  5055.  
  5056. I open a 3270 window and an OS/2 window with very small font set in
  5057. each, exec SCHEDULR and bring up WINDOW LIST. I can then monitor
  5058. the sessions as they get created and watch the PRINT_STATUS output.
  5059. Note that in the OS/2 START command, you can specify a string to
  5060. use as the name of the session. It's easy to supply the filename
  5061. you are passing to the STARTed CMD so that WINDOW LIST will display
  5062. the names of the files being processed.
  5063.  
  5064. for example:
  5065.  
  5066. filename=parts.dat
  5067. 'start  "Uploading' filename '" /FS /B /C /MIN UPLOAD.CMD' parms
  5068.  
  5069. The WINDOW LIST and the minimized OS/2 session ICON title will
  5070. display    Uploading parts.dat
  5071.  
  5072. SCHEDULR will simultaneously convert 1 file & upload 1 file as long
  5073. as a file is ready for each operation. Since uploading takes longer
  5074. than converting, in my case, I have a subroutine which sorts the file
  5075. names before starting based on their size, smallest to largest. This
  5076. way, UPLOAD never waits on CONVERT, except for the 1st file.
  5077.  
  5078. I'm sure you can adapt the above for your use. I also sure that there's
  5079. many other ways to do it. I'd be interested to suggestions for
  5080. improvement. This is my first in-depth use of REXX and it has become
  5081. my favorite language to code in. Good luck!
  5082.  
  5083. Gary Richardi
  5084. IBM Development & Integration Services, Los Angeles
  5085.  
  5086. ----- OS2REXX CFORUM appended at 12:02:27 on 92/08/14 GMT (by MCGUIRE at GDLVM7)
  5087. Subject: REXX futures
  5088. Ref:     Append at 20:24:10 on 92/08/13 GMT (by SAMI3QU at OS2CUST)
  5089.  
  5090. 1)  To really meet the goals of an object oriented Rexx, the entire package
  5091. is needed.  The biggest requirement we need to satisfy right is the need for
  5092. a "Visual Rexx" type of product.  I'm not able to talk about schedules yet,
  5093. other than just the "general timeframe" type of statements I made in the
  5094. FTN.
  5095.  
  5096. 2)  The Rexx language is currently under the control of an SAA Architecture
  5097. board that determines what the definition of Rexx is and what features are
  5098. part of the common implementations.  The starting point for the SAA defintion
  5099. is the Mike Cowlishaw book, "The REXX Language".  This is Mike's formalization
  5100. of the Rexx language that appeared after the first implementation was
  5101. available on CMS.  When Mike wrote this book, he applied some 20-20 hindsight
  5102. to what had been implemented on CMS and determined that some features really
  5103. did not belong as part of a formalized Rexx language definition.  Some
  5104. features were redundant (such as INDEX()), not extensible (such as Parse
  5105. Numeric), or difficult to rigorously define in a way that was truely useful
  5106. (JUSTIFY() is an example of this).  These features are considered CMS
  5107. "extensions" to the REXX language.
  5108.  
  5109. "The REXX Language" also included some features that hadn't been implemented
  5110. on any platforms yet.  The most notable new feature was a set of native I/O
  5111. functions (linein(), lineout(), and others).  The OS/2 implementation was the
  5112. first IBM REXX interpreter to support these, and these functions will also
  5113. be added to the other REXX interpreters in the future.
  5114.  
  5115. Rick McGuire - SAA Rexx Development, Endicott
  5116.  
  5117. ----- OS2REXX CFORUM appended at 12:44:45 on 92/08/14 GMT (by PERSHNG at YKTVMH)
  5118. Subject: REXX futures
  5119. Ref:     Append at 20:24:10 on 92/08/13 GMT (by SAMI3QU at OS2CUST)
  5120.  
  5121. Note that the "official" (SAA) REXX language definition is "Systems
  5122. Application Architecture, Common Programming Interface:  Procedures
  5123. Language Level 2 Reference", SC24-5549.  I believe that, for better or
  5124. worse, the OS/2 variant of REXX follows this definition almost to the
  5125. letter, whereas the CMS implementation contains a number of useful
  5126. "extensions" that are not in the SAA definition.
  5127.  
  5128. John A. Pershing Jr.
  5129.  
  5130. ----- OS2REXX CFORUM appended at 13:22:47 on 92/08/14 GMT (by IL10966 at OS2CUST)
  5131. Subject: FTN Samples
  5132.  
  5133. Rick,
  5134.  
  5135. Yesterday's FTN was great!  I was wondering if you could post your
  5136. ObjectVision .OVD file and the REXX code it used here or on CompuServe.
  5137. It looks like a good quick example I could share with others.
  5138.  
  5139. Kevin L. Herstad, Fort Wayne Community Schools
  5140.  
  5141. ----- OS2REXX CFORUM appended at 14:02:53 on 92/08/14 GMT (by MCGUIRE at GDLVM7)
  5142. Subject: FTN Samples
  5143. Ref:     Append at 13:22:47 on 92/08/14 GMT (by IL10966 at OS2CUST)
  5144.  
  5145. No problem.  I've had a number of requests for this already, so I'll put it
  5146. both here and on CompuServe.
  5147.  
  5148. Rick McGuire - SAA Rexx Development, Endicott
  5149.  
  5150. ----- OS2REXX CFORUM appended at 15:18:10 on 92/08/14 GMT (by SAMI3QU at OS2CUST)
  5151. Subject: REXX futures
  5152. Ref: Append at 12:02:27 on 92/08/14 GMT (by MCGUIRE at GDLVM7)
  5153.  
  5154. Rick,
  5155.  
  5156. Thanks for the information.  I wasn't aware of the particulars as far as
  5157. the various implementations are concerned.  I've been writing REXX code on
  5158. VM and MVS a lot longer than OS/2 and have the tendency to think of the VM
  5159. implementation as the "standard".  It will be a great day when we don't need
  5160. EXECIO anymore!
  5161.  
  5162. Mark Thompson - Coal Services Corp.  St. Louis, MO
  5163.  
  5164. ----- OS2REXX CFORUM appended at 17:43:59 on 92/08/14 GMT (by IL19543 at OS2CUST)
  5165. Subject: REXX futures
  5166. Ref: Append at 12:02:27 on 92/08/14 GMT (by MCGUIRE at GDLVM7)
  5167.  
  5168. Rick, or someone,
  5169. I enjoyed you REXX FTN the other day.  I have one question -when, or will,
  5170. REXX be ported to AIX?
  5171. Thanks,
  5172.  
  5173. Mike Long - CARD Iowa State University - PC/LAN Analyst
  5174.  
  5175. ----- OS2REXX CFORUM appended at 18:01:30 on 92/08/14 GMT (by SRPIE05 at OS2CUST)
  5176. Subject: Communication between REXX programs on separate workstations
  5177.  
  5178.   Does anyone know of a way to communicate between 2 REXX programs running
  5179. on separate machines on a TR network?  We currently just have the separate
  5180. machines monitor a file on a server.  It would be nice to perform this
  5181. communication via a named pipe or a shared queue.  Can we do this with REXX?
  5182.  
  5183. Thanks.
  5184.  
  5185. Thane Smith - Salt River Project
  5186.  
  5187. ----- OS2REXX CFORUM appended at 18:09:44 on 92/08/14 GMT (by MCGUIRE at GDLVM7)
  5188. Subject: REXX futures
  5189. Ref:     Append at 17:43:59 on 92/08/14 GMT (by IL19543 at OS2CUST)
  5190.  
  5191. We currently don't have any plans in place to make it available on AIX,
  5192. although the port from OS/2 to AIX would not be particularly difficult to
  5193. do.  I'm not saying we won't ever do it, but currently we don't have any
  5194. thing "in plan" for AIX.
  5195.  
  5196. Rick McGuire - SAA Rexx Development, Endicott
  5197.  
  5198. ----- OS2REXX CFORUM appended at 18:14:07 on 92/08/14 GMT (by MCGUIRE at GDLVM7)
  5199. Subject: Communication between REXX programs on separate workstations
  5200. Ref:     Append at 18:01:30 on 92/08/14 GMT (by SRPIE05 at OS2CUST)
  5201.  
  5202. A named pipe could be used, but Rexx can only access a named pipe on the
  5203. client end currently (i.e., is unable to do the create and connect operations),
  5204. you may need to have an intermediate server that the two Rexx programs can
  5205. connect to.
  5206.  
  5207. Another alternative is the Rexx CPICOMM communications interface.  This is
  5208. part of Communications Manager in Extended Services or can also be obtained
  5209. as part of the Network Services/2 product (for 1.3 systems).  This provides
  5210. the SAA Communications API, and can even talk to Rexx programs on VM, MVS
  5211. and OS/400 systems, since they all support the same CPICOMM interface.
  5212.  
  5213. Rick McGuire - SAA Rexx Development, Endicott
  5214.  
  5215. ----- OS2REXX CFORUM appended at 19:22:09 on 92/08/14 GMT (by SRPIE05 at OS2CUST)
  5216. Subject: Communication between REXX programs on separate workstations
  5217. Ref: Append at 18:14:07 on 92/08/14 GMT (by MCGUIRE at GDLVM7)
  5218.  
  5219.   The CPICOMM function sounds like exactly what I need.  I can't seem to find
  5220. any mention of it in any documentation I have (REXX or ES).  Is there a
  5221. special manual that explains the use of this and/or how to use it with REXX?
  5222.  
  5223. Thanks.
  5224.  
  5225. Thane Smith - Salt River Project
  5226.  
  5227. ----- OS2REXX CFORUM appended at 20:04:34 on 92/08/14 GMT (by MCGUIRE at GDLVM7)
  5228. Subject: Communication between REXX programs on separate workstations
  5229. Ref:     Append at 19:22:09 on 92/08/14 GMT (by SRPIE05 at OS2CUST)
  5230.  
  5231. Several hundred pounds of manuals in my office, and I never seem to have the
  5232. one I need <G>.  I did find a section on the OS/2 Rexx interface in the
  5233. SAA CPI Communcations Reference that describes how to access the Rexx support
  5234. (manual number SC26-4399-03).  This manual includes references to
  5235. the NS/2 manuals, and I believe that there are equivalents for
  5236. Extended Services/2 also.  The current level of the SAA reference is
  5237. SC26-4399-05.
  5238.  
  5239. I just took a peek over in the Communications Manager forum, and there is a
  5240. CM Sample Programs Diskette available that contains documentation and
  5241. sample code for using the CPICREXX support.  The order number is S04G-1031.
  5242.  
  5243. Rick McGuire - SAA Rexx Development, Endicott
  5244.  
  5245. ----- OS2REXX CFORUM appended at 00:08:49 on 92/08/17 GMT (by UDSS013 at OS2CUST)
  5246. Subject: REXX futures
  5247.  
  5248. |  I enjoyed you REXX FTN the other day.  I have one question -when, or will |
  5249. |  REXX be ported to AIX?                                                    |
  5250.  
  5251. I second the motion.  The ksh script language is not what I have in mind
  5252. when I think of a modern scripting language.  A lot of times, I will write
  5253. the REXX code under OS/2 and process AIX data on an NFS-mounted drive, just
  5254. so I can get the work out.  I would LOVE to have a native REXX port for AIX.
  5255.  
  5256. Rumor has it that there is an IBM internal version of REXX for AIX.  If so,
  5257. I would encourage you to release it, even as an added cost program product.
  5258. If there isn't one available, I would think that the 32-bit REXX for OS/2
  5259. should be a straightforward port.
  5260.  
  5261. Gary "An ISU Alum" Murphy
  5262.  
  5263. Again, apologies to Wayne Holmes.
  5264.  
  5265. Gary Murphy
  5266.  
  5267. ----- OS2REXX CFORUM appended at 16:39:35 on 92/08/17 GMT (by NAAO3IY at OS2CUST)
  5268. Subject: REXX -- today's date only???
  5269.  
  5270.    Am I missing something, or has Mr. Cowlishaw committed the folly
  5271. of including support for approximately twelvety-'leven date formats
  5272. in REXX and then quite spoilt the effect by making them accessible
  5273. only to obtain today's date?
  5274.  
  5275.    If so, it's no big problem for me -- I have routines in REXX that
  5276. convert back and forth between dates in the Gregorian or Julian
  5277. Calendars and Julian Dates, but it seems so _silly_ to have all the
  5278. necessary code for date arithmetic already in any REXX
  5279. implementation, but unaccessible to the REXX programmer.  It is a minor
  5280. annoyance, too, that amoung all the date formats included, the Julian
  5281. Date (which, after all, has been the standard for centuries) is not one.
  5282.  
  5283.    By the way, for those of you who don't know, the Julian Calendar
  5284. and the Julian Date have nothing in particular to do with one
  5285. another; they were just, by an unfortunate historical coincidence,
  5286. both named at roughly the same time after two different men named
  5287. "Julius".  Also, the Julian Date is not yy.ddd (as if things weren't
  5288. confused enough before some addlepate decided to muddy the waters by
  5289. introducing this ringer); rather, the Julian Date is the number of
  5290. days elapsed since January 1, 4713 BC (Julian Calendar).
  5291.  
  5292. John Kennedy -- Hoechst Celanese, Bridgewater, NJ
  5293.  
  5294. ----- OS2REXX CFORUM appended at 17:08:12 on 92/08/17 GMT (by WOAN at AUSVM6) -
  5295. Subject: REXX futures
  5296. Ref:     Append at 00:08:49 on 92/08/17 GMT (by UDSS013 at OS2CUST)
  5297.  
  5298. I assume that people realize that a third party REXX product
  5299. which is generally the standard for REXX on UNIX workstations
  5300. is available from the Workstation Group for AIX?
  5301.  
  5302. No flame wars, but if you haven't already, you might look at
  5303. PERL, TCL, PYTHON, or any of a host of other freely available
  5304. languages available for AIX/UNIX. That way you can trade
  5305. scripts with you other UNIX colleagues around the world and
  5306. take advantage of such things as X/Motif interfaces,
  5307. direct access to a variety of third party database products,
  5308. and tons of freely available code.
  5309.  
  5310. Ron, WOAN AT AUSTIN
  5311.  
  5312. ----- OS2REXX CFORUM appended at 05:00:34 on 92/08/18 GMT (by JL07784 at YMTVM8)
  5313. Subject: How to check the Diskette drive status, ready or not ready ?
  5314. Ref:     Append at 14:40:43 on 92/08/10 GMT (by MRTOM at YKTVMV)
  5315.  
  5316. Thank you Tom,
  5317. But I think REXXUTIL is not included in the OS/2 REXX package.
  5318. RXUTILS is very useful, but it will be run in IBM internal.
  5319. This program will be run in the customer, so they must not have
  5320. REXXUTILS. I assume that our customers install REXX.
  5321. And I don't want to write any special program to check the drive
  5322. status. Do you have other good idea ?
  5323. Thank you.
  5324.  
  5325. M. Yamamoto
  5326.  
  5327. ----- OS2REXX CFORUM appended at 12:57:11 on 92/08/18 GMT (by PERSHNG at YKTVMH)
  5328. Subject: How to check the Diskette drive status, ready or not ready ?
  5329. Ref:     Append at 05:00:34 on 92/08/18 GMT (by JL07784 at YMTVM8)
  5330.  
  5331. No -- REXXUTIL *is* included with OS/2 2.0 (or, at least, a very large
  5332. subset of the IUO package).  Of course, if you are developing something
  5333. for a customer, then you need to test it against the PID version of
  5334. REXXUTIL.
  5335.  
  5336. On an OS/2 2.0 system, go to the "Information" folder, open the "REXX
  5337. Information" book, and look in the TOC for "REXXUTIL".
  5338.  
  5339. John A. Pershing Jr.
  5340.  
  5341. ----- OS2REXX CFORUM appended at 13:03:32 on 92/08/18 GMT (by IL10966 at OS2CUST)
  5342. ..... OS2REXX CFORUM modified at 00:22:05 on 92/08/21 GMT (by IL10966 at OS2CUST)
  5343. Subject: FTN Samples
  5344. This APPEND was deleted at 20:22:04 on 08/20/92 EST.
  5345.  
  5346. ----- OS2REXX CFORUM appended at 14:50:41 on 92/08/18 GMT (by HQ4NMAH at OS2CUST)
  5347. Subject: Concatenating strings in REXX
  5348.  
  5349. I need to concatenate 2 strings together to come up with a file name.  The
  5350. user will supply the first 8 characters of the file name and I will supply
  5351. the last 3 characters which will always be constant.  Is there a STRCAT or
  5352. some kind of concat function??
  5353.  
  5354. mark Hixson
  5355.  
  5356. ----- OS2REXX CFORUM appended at 14:55:41 on 92/08/18 GMT (by VERSTEEG at UITVM1)
  5357. Subject: Concatenating strings in REXX
  5358. Ref:     Append at 14:50:41 on 92/08/18 GMT (by HQ4NMAH at OS2CUST)
  5359.  
  5360. Try this:
  5361. /* assuming userinput contains the input from the user already */
  5362. filename=userinput'.EXT'
  5363. or
  5364. filename=userinput||'.EXT'
  5365.  
  5366. Anton Versteeg - ESAT PWS CoC Uithoorn, NL  *** 1,000,000 OS/2 2.0 ***
  5367.  
  5368. ----- OS2REXX CFORUM appended at 01:06:15 on 92/08/19 GMT (by JL07784 at YMTVM8)
  5369. Subject: How to check the Diskette drive status, ready or not ready ?
  5370. Ref:     Append at 12:57:11 on 92/08/18 GMT (by PERSHNG at YKTVMH)
  5371.  
  5372. Thank you for your append. I'm sorry for my insufficient append.
  5373. I know REXXUTIL is included with OS/2 2.0, but is *NOT* included
  5374. with OS/2 1.3. My program must run both operating system.
  5375. So I cannot use REXXUTIL such like SysDriveInfo() functions.
  5376. Does standard REXX-OS/2 have such function ?
  5377. Thank you.
  5378.  
  5379. M. Yamamoto
  5380.  
  5381. ----- OS2REXX CFORUM appended at 01:12:29 on 92/08/19 GMT (by BABKA at GDLVM7)
  5382. Subject: Concatenating strings in REXX
  5383. Ref:     Append at 14:50:41 on 92/08/18 GMT (by HQ4NMAH at OS2CUST)
  5384.  
  5385. Oh, how we love straight men! <G>  This is one of the things REXX is
  5386. made for!  To concatenate two strings, just put them together.  Now,
  5387. before you accuse me of restating the obvious, let me give you an
  5388. example
  5389.  
  5390. If the variable 'filename' has the file name your user provided, and you
  5391. want to add '.ABC' to the end of it, just write:
  5392.  
  5393. (1) new_filename = filename'.ABC'
  5394.  
  5395. or, you can use the explicit concatenation operator, ||, like this:
  5396.  
  5397. (2) new_filename = filename || '.ABC'
  5398.  
  5399. Obviously, if you had another variable instead of '.ABC', you'd need to
  5400. use the second form (e.g. filename || ext).  Otherwise, REXX would see
  5401. filenameext as one variable name.  Just for completeness, if you want to
  5402. put two strings together with a blank in between, you have several
  5403. choices:
  5404.  
  5405. (3) new_string = string1 string2
  5406. (4) new_string = string1' 'string 2
  5407. (5) new_string = string1' ' || string2
  5408. etc., etc.,...
  5409.  
  5410. So, for direct concatenation, use either direct abuttal (1) or the ||
  5411. operator (2).  For concatenation with a blank, use the blank operator
  5412. (3).
  5413.  
  5414. Jim Babka
  5415.  
  5416. ----- OS2REXX CFORUM appended at 03:26:04 on 92/08/19 GMT (by IL26761 at HONE84)
  5417. Subject: How to check the Diskette drive status, ready or not ready ?
  5418. Ref: Append at 05:00:34 on 92/08/18 GMT (by JL07784 at YMTVM8)
  5419.  
  5420. REXXUTIL is included with the OS/2 system I believe.
  5421.  
  5422. Jack Hiatt  Marc Life  Atlanta Ga.
  5423.  
  5424. ----- OS2REXX CFORUM appended at 12:59:31 on 92/08/19 GMT (by PERSHNG at YKTVMH)
  5425. Subject: How to check the Diskette drive status, ready or not ready ?
  5426. Ref:     Append at 01:06:15 on 92/08/19 GMT (by JL07784 at YMTVM8)
  5427.  
  5428. No, the "standard" REXX that comes with 1.3 does not have those functions.
  5429.  
  5430. I don't know enough about OS/2 to suggest a work-around.  Perhaps you
  5431. should try asking in one of the other OS/2 forums, making it clear that
  5432. (1) it has to work on 1.3 and (2) IUO software is not an option.
  5433.  
  5434. (Unless you can swing some sort of deal to "sell" a copy of the 2.0 version
  5435. of REXXUTIL to your 1.3 customer -- it probably works under 1.3...)
  5436.  
  5437. John A. Pershing Jr.
  5438.  
  5439. ----- OS2REXX CFORUM appended at 18:07:09 on 92/08/19 GMT (by GBFORNEY at WASVMIC5)
  5440. Subject: How to check the Diskette drive status, ready or not ready ?
  5441. Ref:     Append at 12:59:31 on 92/08/19 GMT (by PERSHNG at YKTVMH)
  5442.  
  5443. REXXUTIL is 32 bit and will *not* work under 1.3.
  5444.  
  5445. Greg Forney  bigred@vnet.ibm.com
  5446.  
  5447. ----- OS2REXX CFORUM appended at 23:51:51 on 92/08/19 GMT (by SDETWEIL at DETVMIC4)
  5448. ..... OS2REXX CFORUM modified at 23:06:44 on 92/08/20 GMT (by SDETWEIL at DETVMIC4)
  5449. Subject: Concatenating strings in REXX
  5450. Ref:     Append at 01:12:29 on 92/08/19 GMT (by BABKA at GDLVM7)
  5451.  
  5452. I agree with everything Jim said, with one additional
  5453. note.
  5454.  
  5455. For future readability and maintenance, PLEASE, PLEASE, PLEASE
  5456. do NOT use the direct abuttal technique when using literals.
  5457.  
  5458. a = 'something'test
  5459. a = something'test'
  5460. This will burn someone later
  5461.  
  5462. Use the abuttal operator
  5463.  
  5464. a = 'something' || test
  5465. a = something || 'test'
  5466.  
  5467. This makes your intent clear and avoids this pitfall...
  5468.  
  5469. Sam
  5470.  
  5471. ----- OS2REXX CFORUM appended at 00:09:02 on 92/08/21 GMT (by UDSS013 at OS2CUST)
  5472. Subject: Concatenating strings in REXX
  5473.  
  5474. |  For future readability and maintenance, PLEASE, PLEASE, PLEASE            |
  5475. |  do NOT use the direct abuttal technique when using literals.              |
  5476.  
  5477. I do that ALL THE TIME.  I consider that one of the neat semantics of REXX.
  5478. Sure, it took a little while to get used to looking at the code, but I like
  5479. it sooooo......
  5480.  
  5481. PLEASE, PLEASE, PLEASE don't change the language definition to make this
  5482. illegal!
  5483.  
  5484. Gary Murphy
  5485.  
  5486. ----- OS2REXX CFORUM appended at 01:41:22 on 92/08/21 GMT (by SDETWEIL at DETVMIC4)
  5487. Subject: Concatenating strings in REXX
  5488. Ref:     Append at 00:09:02 on 92/08/21 GMT (by UDSS013 at OS2CUST)
  5489.  
  5490. The language won't change, so there's no problem there..
  5491.  
  5492. Just remember later when someone hands you 2-5k lines of rexx
  5493. code why it is so hard to debug...
  5494.  
  5495. (ps. I wrote the prototype of the OS/2 rexx interpreter so
  5496. I do occasionally know something about rexx)
  5497.  
  5498. Sam
  5499.  
  5500. ----- OS2REXX CFORUM appended at 12:41:26 on 92/08/21 GMT (by MRTOM at YKTVMV)
  5501. Subject: Concatenating strings in REXX
  5502. Ref:     Append at 01:41:22 on 92/08/21 GMT (by SDETWEIL at DETVMIC4)
  5503.  
  5504. It all depends on what you're used to.  I don't use || unless it's
  5505. needed, so when I look at someone else's code where it's used and not
  5506. needed, it's distracting.  If I've inherited that code, I usually
  5507. pull the unnecessary ||s out.
  5508.  
  5509. Tom
  5510.  
  5511. ----- OS2REXX CFORUM appended at 13:47:57 on 92/08/21 GMT (by VERSTEEG at UITVM1)
  5512. Subject: Concatenating strings in REXX
  5513. Ref:     Append at 12:41:26 on 92/08/21 GMT (by MRTOM at YKTVMV)
  5514.  
  5515. I agree. Take the following sample.
  5516.  
  5517. /* */
  5518. a='ABC'
  5519. z='XYZ'
  5520. aa = a'-'z
  5521.  
  5522. I prefer this over:
  5523.  
  5524. az = a||'-'||z
  5525.  
  5526. It's shorter and more readable IMHO.
  5527. Only when you want to concatenate a and z you would need:
  5528. az = a||z
  5529.  
  5530. Anton Versteeg - ESAT PWS CoC Uithoorn, NL  *** 1,000,000 OS/2 2.0 ***
  5531.  
  5532. ----- OS2REXX CFORUM appended at 13:58:21 on 92/08/21 GMT (by SDETWEIL at DETVMIC4)
  5533. Subject: Concatenating strings in REXX
  5534. Ref:     Append at 13:47:57 on 92/08/21 GMT (by VERSTEEG at UITVM1)
  5535.  
  5536. Well, as one can see this is a matter of style...
  5537.  
  5538. Each opinion is correct..oh well
  5539.  
  5540. Sam, I hate az = a'-'z'+'b'*'c'/'d
  5541.  
  5542. ----- OS2REXX CFORUM appended at 15:11:11 on 92/08/21 GMT (by RSBAKER at ATLVM1)
  5543. Subject: Concatenating strings in REXX
  5544. Ref:     Append at 13:47:57 on 92/08/21 GMT (by VERSTEEG at UITVM1)
  5545.  
  5546. > I prefer this over:
  5547. >
  5548. > az = a||'-'||z
  5549.  
  5550. Yes, but we whitespace fanatics would write this as:
  5551.  
  5552. az = a || '-' || z
  5553.  
  5554. This looks clearer to me, but then it is largely a matter of taste.
  5555.  
  5556. Randy Baker
  5557.  
  5558. ----- OS2REXX CFORUM appended at 15:18:06 on 92/08/21 GMT (by SAMI3QU at OS2CUST)
  5559. Subject: Minor problem with SysSetObjectData
  5560.  
  5561. I'm using the SysSetObjectData function to start some programs and have
  5562. encountered a minor problem (at least I think it's a problem).  I have a
  5563. Program Reference that runs a DOS application in a window.  I used the
  5564. SysSetObjectData function to set the MAXIMIZED=YES attribute so the app will
  5565. start in a maxmimized window.  This works just fine when I double-click on
  5566. the icon.  However, if I start the app using SysSetObjectData with a setup
  5567. string of "OPEN=DEFAULT", the PR loses the MAXIMIZED=YES attribute (not just
  5568. on that invocation, but permanently).  This is not a major problem and can be
  5569. easily circumvented by changing the setup to "OPEN=DEFAULT;MAXIMIZED=YES", but
  5570. I'm concerned that other settings may be lost that I just haven't noticed yet.
  5571. Thanks in advance for any help or info.
  5572.  
  5573. Mark Thompson - Coal Services Corp.  St. Louis, MO
  5574.  
  5575. ----- OS2REXX CFORUM appended at 15:29:22 on 92/08/21 GMT (by NBLKCY0 at OS2CUST)
  5576. Subject: Using SysCreateObject to set DOS_VERSION
  5577.  
  5578. I am trying to create a program object for 123 3.1+ and need to specify
  5579. multiple programs in the DOS_VERSION setting.  All attempts have resulted
  5580. in only the first DOS_VERSION setting being recognized.
  5581.  
  5582. Can anyone provide an example of how I can set this up?
  5583.  
  5584. I need to set 123.exe,3,40,255 and 123dos.exe,3,40,255 in a single
  5585. SysCreateObject command.
  5586.  
  5587. John Wilson - Citizens Fidelity Bank
  5588.  
  5589. ----- OS2REXX CFORUM appended at 15:54:59 on 92/08/21 GMT (by XXCDSX26 at TORVMCOP)
  5590. Subject: Using SysCreateObject to set DOS_VERSION
  5591. Ref:     Append at 15:29:22 on 92/08/21 GMT (by NBLKCY0 at OS2CUST)
  5592.  
  5593. John:
  5594.  
  5595. I believe you can specify the DOS_VERSION as "123*.EXE,3,40,255" (or
  5596. *.*,3,40,255 if you really wanted to).
  5597.  
  5598. Michael Harper - Cdn Depository for Securities, Ltd
  5599.  
  5600. ----- OS2REXX CFORUM appended at 17:13:26 on 92/08/21 GMT (by NAAO3IY at OS2CUST)
  5601. Subject: Concatenating strings in REXX
  5602. Ref: Append at 15:11:11 on 92/08/21 GMT (by RSBAKER at ATLVM1)
  5603.  
  5604.   I tend to split the difference.  I use || in REXX statements, but direct
  5605. abuttment in commands:
  5606.  
  5607.      A = B || ' ';
  5608.  
  5609. but
  5610.  
  5611.     "COPY "name".C "name".BAK";
  5612.  
  5613. John Kennedy -- Hoechst Celanese, Bridgewater, NJ
  5614.  
  5615. ----- OS2REXX CFORUM appended at 17:13:40 on 92/08/21 GMT (by NAAO3IY at OS2CUST)
  5616. Subject: Concatenating strings in REXX
  5617. Ref: Append at 15:11:11 on 92/08/21 GMT (by RSBAKER at ATLVM1)
  5618.  
  5619.  (no text entered)
  5620.  
  5621. John Kennedy -- Hoechst Celanese, Bridgewater, NJ
  5622.  
  5623. ----- OS2REXX CFORUM appended at 17:15:33 on 92/08/21 GMT (by CONT00 at LEXVMK)
  5624. Subject: Using SysCreateObject to set DOS_VERSION
  5625. Ref:     Append at 15:29:22 on 92/08/21 GMT (by NBLKCY0 at OS2CUST)
  5626.  
  5627. Try to separate the entries for DOS_VERSION with '0A'x (line-feed)...
  5628.  
  5629. Gregory Czaja, Lexington 8-545-3311  1992/08/21  13:14
  5630.  
  5631. ----- OS2REXX CFORUM appended at 20:03:42 on 92/08/27 GMT (by XXMUTL27 at TORVMCOP)
  5632. Subject: GetEA and extended attributes
  5633. Ref:     Append at 17:13:15 on 92/07/24 GMT (by XXMUTL27 at TORVMCOP)
  5634.  
  5635. GetEA will allow me to get the value of an extended attribute from
  5636. a file if I know the name of the the attribute.  Is there a way (from
  5637. within a REXX program) that I can determine what extended attributes
  5638. (if any) are associated with a given file?
  5639.  
  5640. Any help would be appreciated.  Thanks in advance
  5641.  
  5642. ---------------------------------------------------------------------
  5643.  
  5644. About a month ago I asked the following question.  Unfortunately
  5645. (for me anyways), I've had no response.  Even a reply of "no, can't
  5646. be done" would be better than nothing.
  5647.  
  5648. Again, thanks for any help.
  5649.  
  5650. Erik Vander Ahe
  5651. The Mutual Group
  5652. Waterloo, Ontario
  5653.  
  5654. ----- OS2REXX CFORUM appended at 11:20:32 on 92/08/28 GMT (by MCGUIRE at GDLVM7)
  5655. Subject: GetEA and extended attributes
  5656. Ref:     Append at 20:03:42 on 92/08/27 GMT (by XXMUTL27 at TORVMCOP)
  5657.  
  5658. No, it can't be done currently, although a REXXUTIL function to return the
  5659. list is a candidate for a future release.
  5660.  
  5661. Rick McGuire - SAA Rexx Development, Endicott
  5662.  
  5663. ----- OS2REXX CFORUM appended at 13:10:27 on 92/08/28 GMT (by XXMUTL27 at TORVMCOP)
  5664. Subject: GetEA and extended attributes
  5665. Ref:     Append at 11:20:32 on 92/08/28 GMT (by MCGUIRE at GDLVM7)
  5666.  
  5667. Thanks for your reply Rick.  I thought that that's what the reply
  5668. would be, but I wanted to make sure.  It is disappointing though.  Can
  5669. you give some kind of time frame as to when such a function might be
  5670. available?
  5671.  
  5672. Thanks
  5673.  
  5674. Erik Vander Ahe
  5675. The Mutual Group
  5676. Waterloo, Ontario
  5677.  
  5678. ----- OS2REXX CFORUM appended at 13:39:59 on 92/08/28 GMT (by MCGUIRE at GDLVM7)
  5679. Subject: GetEA and extended attributes
  5680. Ref:     Append at 13:10:27 on 92/08/28 GMT (by XXMUTL27 at TORVMCOP)
  5681.  
  5682. Can't really give you a time frame yet, since I'm not really sure myself!
  5683.  
  5684. Rick McGuire - SAA Rexx Development, Endicott
  5685.  
  5686. ----- OS2REXX CFORUM appended at 19:27:45 on 92/08/28 GMT (by IL12431 at OS2CUST)
  5687. Subject: Evaluating contention performance
  5688.  
  5689. Please refer to my append with this same header in the Database Manager forum.
  5690. I'm looking for an API, preferably REXX, that permits me to get the sum and
  5691. average of record/table lock contentions managed by the DBM.
  5692.  
  5693. Dave Scheffer
  5694.  
  5695. ----- OS2REXX CFORUM appended at 20:09:45 on 92/08/30 GMT (by PMUELLR at CARVM3)
  5696. Subject: GetEA and extended attributes
  5697. Ref:     Append at 13:10:27 on 92/08/28 GMT (by XXMUTL27 at TORVMCOP)
  5698.  
  5699. You could do call EAUTIL to 'split and preserve' (I believe /S /R /P)
  5700. and then read through the EA file yourself.  Kludgey and slower than
  5701. an external rexx function to enumerate the EAs, but do-able.
  5702.  
  5703. Patrick Mueller - IBM Cary
  5704.  
  5705. ----- OS2REXX CFORUM appended at 10:42:25 on 92/08/31 GMT (by 83829325 at VALVM1)
  5706. Subject: rex0043 and sqldbs
  5707.  
  5708. I need to use REXX to define a collating sequence to DBM, but whenever
  5709. I write 'call SQLDBS 'CREATE DATABASE XXXX'" I receive a rex0043 error
  5710. saying that they can't find the routine. I have seen than I have
  5711. sqlar.dll in sqllib\dll, and I have also the path OK, and I call
  5712. rxfuncadd('sqldbs','sqlar','sqldbs) in my program just before sayin the
  5713. 'call sqldbs...'
  5714.  
  5715.    What on earth am I doing wrong???
  5716.  
  5717. ----- OS2REXX CFORUM appended at 12:31:23 on 92/08/31 GMT (by CNADLER at WMAVM1)
  5718. Subject: rex0043 and sqldbs
  5719. Ref:     Append at 10:42:25 on 92/08/31 GMT (by 83829325 at VALVM1)
  5720.  
  5721. Did you check the return from the RxFuncAdd? It may have returned an
  5722. error that you are not catching, and if so, will probably point to the
  5723. real error.
  5724.  
  5725. Cliff Nadler                                         GO TEAM OS/2!
  5726. Systems Integration and Services                     Rockville, MD
  5727. IBM Federal Systems Company                PROFS: NADLER at WMAVM7
  5728.  
  5729. ----- OS2REXX CFORUM appended at 16:17:28 on 92/08/31 GMT (by IL32772 at OS2CUST)
  5730. Subject: Edit files via Rexx
  5731.  
  5732. How can I update an line in a file with rexx?  I have been able to
  5733. read lines from files, config.sys for example, and write a line, but
  5734. not replace the line read.  I am attempting to use LINEIN and LINEOUT
  5735. but am only able to reset the position to line 1, not line 10, for
  5736. example.  The intent is to be able to load code and directories to a
  5737. system, update the config.sys when needed, and confirm the updates
  5738. using one rexx command.
  5739.  
  5740. Randy Cairns
  5741.  
  5742. ----- OS2REXX CFORUM appended at 17:31:11 on 92/08/31 GMT (by NAAO3IY at OS2CUST)
  5743. Subject: Edit files via Rexx
  5744. Ref: Append at 16:17:28 on 92/08/31 GMT (by IL32772 at OS2CUST)
  5745.  
  5746. You can't do what you want in REXX -- but you can't do it in any other
  5747. language, either.  Text files in OS/2 (and DOS, for that matter) are just
  5748. glops of bytes with hex 0D0A between the "lines".  The most you could do,
  5749. therefore, would be to update individual characters, without changing the
  5750. size of the lines.
  5751.  
  5752. You can either suck the whole thing into memory and then write it all
  5753. out again or else create a new file and copy your input file to it, with the
  5754. changes you want, and then scratch the original and rename the new one to
  5755. the old name.
  5756.  
  5757. John Kennedy -- Hoechst Celanese, Bridgewater, NJ
  5758.  
  5759. ----- OS2REXX CFORUM appended at 18:46:11 on 92/08/31 GMT (by NIBMDAVD at RALVMS)
  5760. Subject: file i/o and stems
  5761.  
  5762. I'm am trying to perform updates on batches of files using rexx. But the
  5763. linein/lineout functions seem to be incredibly slow.
  5764.  
  5765. What I would like to do is write an external function which will perform
  5766. all my file i/o in one fell swoop, either reading it from a file into a
  5767. stem, or writing from a stem into a file. This is what I end up doing
  5768. anyway...using linein/lineout and a DO loop.
  5769.   A similar function exists on the host with IOX. I've been really
  5770. spoiled using that, but now I have to work on OS/2.
  5771.  
  5772. - Does something like this already exist? Has anybody already written it?
  5773.  
  5774. - Where do I go to find an example of an external function passing a
  5775.   stem variable?
  5776.  
  5777. David Erickson, NIBMDAVD at RALVMS
  5778.  
  5779. ----- OS2REXX CFORUM appended at 19:30:00 on 92/09/01 GMT (by NAAO3IY at OS2CUST)
  5780. Subject: file i/o and stems
  5781. Ref: Append at 18:46:11 on 92/08/31 GMT (by NIBMDAVD at RALVMS)
  5782.  
  5783. The EXECIO function of CMS and TSO REXX is a kludge that got added on
  5784. to the REXX processors because no provision had been made for I/O apart
  5785. from PULL and SAY.  It's not part of the language.  LINEIN and LINEOUT
  5786. (and STREAM and CHARIN and CHAROUT) are, and will be added to CMS and
  5787. TSO REXX at the next major cycle, if they have not already been.
  5788.  
  5789. LINEIN and LINEOUT don't seem particularly slow to me.  I can copy over 100KB
  5790. in about six seconds, which seems fast enough for anything I'd want to process
  5791. without benefit of a real compiler in the first place....
  5792.  
  5793. John Kennedy -- Hoechst Celanese, Bridgewater, NJ
  5794.  
  5795. ----- OS2REXX CFORUM appended at 17:19:55 on 92/09/02 GMT (by 86660551 at NHBVM4)
  5796. Subject: file i/o and stems
  5797. Ref:     Append at 18:46:11 on 92/08/31 GMT (by NIBMDAVD at RALVMS)
  5798. You could simulate the stack option of EXECIO by reading the
  5799. entire file at once using charin then manipulating it in memory
  5800. I am doing this from memory - the code may not be syntactically correct
  5801. File=Charin(myfile,1,Chars(Myfile))/* read the whole thing in */
  5802. Crlf='0D0A'x ; Outfile=''
  5803. Do Forever
  5804.   If File ='' Then Leave /* End of file */
  5805.   Parse value File with inline (crlf) File /* gets the next line */
  5806.   Do what you want to do
  5807.   Outfile = Outfile Crlf Newline
  5808.   End
  5809. Call Charout(newfile,1,Length(Outfile))
  5810.  
  5811. I have not used the concatenation symbol - can't find it on my current
  5812. terminal emulator
  5813.  
  5814. Roy Millea
  5815.  
  5816. ----- OS2REXX CFORUM appended at 19:48:31 on 92/09/02 GMT (by BTTUCKER at ATLVM1)
  5817. Subject: Edit files via Rexx
  5818. Ref:     Append at 17:31:11 on 92/08/31 GMT (by NAAO3IY at OS2CUST)
  5819.  
  5820. Here's a neat way to do what you want - I"ll show you how to read
  5821. in a file and be able to operate on each line individually, and
  5822. then we'll discuss how to add or delete lines...
  5823.  
  5824. filename='F:\SUB\FILE.EXT'
  5825.  
  5826. j=1
  5827. do while lines(filename)<>0
  5828.    filein.j=linein(filename)
  5829.    j=j+1
  5830. end /* do */
  5831. filein.0=j
  5832.  
  5833. Now you have a stemmed variable (array) of lines-o-text.  You may
  5834. now use a loop to go through these array elements looking for something,
  5835. alter any text line, etc.
  5836.  
  5837. The trick is in how you add/delete lines.  While processing through
  5838. the lines, write them out to another stemmed variable.  (Iterate
  5839. your counter...)  Don't write the deletions, add in the additions.
  5840. Then your desired output file is contained in the second array.
  5841.  
  5842. Then you:
  5843.  
  5844. out_file='F:\SUB\FILE.EXT'
  5845. do j=1 to file_out.0
  5846.    rc=lineout(out_file,file_out.j)
  5847. end /* do */
  5848.  
  5849. Now you've done what you wanted...                  BT
  5850.  
  5851. ----- OS2REXX CFORUM appended at 19:52:35 on 92/09/02 GMT (by BTTUCKER at ATLVM1)
  5852. ..... OS2REXX CFORUM modified at 20:03:49 on 92/09/02 GMT (by BTTUCKER at ATLVM1)
  5853. Subject: file i/o and stems
  5854. Ref:     Append at 18:46:11 on 92/08/31 GMT (by NIBMDAVD at RALVMS)
  5855.  
  5856. |The charin function can read it in one swell foop, but you are
  5857. the stuck with writing your own code to manipulate the large
  5858. stringy object you get...         BT
  5859.  
  5860. | sorry, wrong function...
  5861.  
  5862. ----- OS2REXX CFORUM appended at 20:31:40 on 92/09/02 GMT (by UDSS013 at OS2CUST)
  5863. Subject: Edit files via Rexx
  5864.  
  5865. |  How can I update an line in a file with rexx?  I have been able to        |
  5866. |  read lines from files, config.sys for example, and write a line, but      |
  5867.  
  5868. If the file is not too big (under 1000 lines), then I would read the entire
  5869. contents of the file into a REXX stem variable.  You can then manipulate
  5870. the in-storage copy as you wish and write it back out.
  5871.  
  5872. You may also want to check out the SysFileSearch routine in REXXUTIL to
  5873. assist.  I was thinking about some code to update CONFIG.SYS and was going
  5874. to read it into a stem and use the SysFileSearch to find the line (e.g.
  5875. LIBPATH=) that I was interested in.   (OK. OK. I don't code for speed <G>).
  5876.  
  5877. If you need some help with stem variables, etc., let me know and I will
  5878. work up some sample code what I get back into the office (09/21).
  5879.  
  5880. Gary Murphy
  5881.  
  5882. ----- OS2REXX CFORUM appended at 13:17:26 on 92/09/04 GMT (by BTTUCKER at ATLVM1)
  5883. Subject: Edit files via Rexx
  5884. Ref:     Append at 20:31:40 on 92/09/02 GMT (by UDSS013 at OS2CUST)
  5885.  
  5886.   Before you do anything, see:
  5887. OS2REXX CFORUM appended at 19:48:31 on 92/09/02 GMT (by BTTUCKER at ATLVM1)
  5888.  
  5889.                                                          BT
  5890.  
  5891. ----- OS2REXX CFORUM appended at 17:42:52 on 92/09/04 GMT (by SHAKOOR at DALHQIC2)
  5892. Subject: A beginners question.
  5893.  
  5894. I have a client who created a dialog box using toolkit 2.0 dialog
  5895. editor.  He wants to know how to use/load this dialog box from within
  5896. his REXX program.
  5897.  
  5898. Does anyone have any sample code for something similar. Any ideas
  5899. help or hints on what all is involved will be greatly appreciated.
  5900.  
  5901. Thanks!
  5902. Shahab Shakoor T/L 421-8032
  5903.  
  5904. ----- OS2REXX CFORUM appended at 00:16:07 on 92/09/05 GMT (by AMBC006 at MARTLINK)
  5905. Subject: REXX as an application driver for DTL
  5906. Ref: Append at 12:23:56 on 92/06/11 GMT (by NAAD356 at OS2CUST)
  5907.  
  5908. If you go to OS/2 Tools, chose OS/2 Documents, and select the APPCMVS option
  5909. you'll get a selection list of programs for the MVS APPC.  You will be
  5910. interested in APPCMVS2 'DMINTER'.  This set of samples has an example of a
  5911. Rexx program that invokes the  DTL stuff.  The DTL compiler was on the 1.3
  5912. Toolkit, but I have not seen it on the 'beta' 2.0 kit.  There was a Red Book
  5913. on the Dialog Manager and it also had an example.  Being a VM/MVS type using
  5914. the Dialog Tag Language is of interest to me.  The DMINTER is the first
  5915. working sample I have seen. - Good Luck.
  5916.  
  5917. Michael Suszko, Jr (A. M. Best Co., Oldwick NJ)
  5918.  
  5919. ----- OS2REXX CFORUM appended at 02:19:33 on 92/09/10 GMT (by RNICHOLS at SYDVM1)
  5920. Subject: Installation Package
  5921.  
  5922. I am currently working on a project that involves producing a
  5923. cooperative processing application between a PS/2 running OS/2 V2.0
  5924. and an AS/400.
  5925.  
  5926. The PS/2 application will be required to be installed at a number of
  5927. remote sites and as such I would like to write an installation
  5928. package to do this.
  5929.  
  5930. The package will primarily need to perform the following tasks:
  5931.   - Create directories
  5932.   - Copy files
  5933.   - Update CONFIG.SYS
  5934.   - Create workplace shell object for the application
  5935.   - Create database manager definitions
  5936.   - Create communications manager network definitions
  5937.  
  5938. I would like to use REXX to write this package and am also prepared to
  5939. use C if required. The package does not need to provide a GUI as a
  5940. text interface is sufficient. It is also assumed that OS/2 V2.0 and
  5941. Extended Services have been installed correctly.
  5942.  
  5943. Does anyone have any experience in writing installation packages and if
  5944. so would they be prepared to share the code as I would like to
  5945. produce this package as quickly as possible.
  5946.  
  5947. Information on how to interface with communications manager in
  5948. particular would be greatly appreciated. Are there API's to install
  5949. network definitions or do I interact directly with .CFG and .NDF files
  5950. from my REXX program. If commuinications manager configuration proves
  5951. to be too difficult then it will have to be done manually.
  5952. Thanks in advance.
  5953.  
  5954. Richard Nicholson SYDVM1(RNICHOLS)
  5955.  
  5956. ----- OS2REXX CFORUM appended at 12:41:54 on 92/09/10 GMT (by CNADLER at WMAVM1)
  5957. Subject: Installation Package
  5958. Ref:     Append at 02:19:33 on 92/09/10 GMT (by RNICHOLS at SYDVM1)
  5959.  
  5960. ES 1.0 has a whole volume on programmable configuration using REXX.
  5961. "Extended Services for OS/2: Programmable Configuration Reference",
  5962. order number S04G-1003-00. You will also want to have the latest fixes
  5963. for REXX (REXX20), and if you look back in this forum, you'll find an
  5964. append by Mike Lamb in Kingston describing how to create workplace shell
  5965. objects (it's a long append, but welll worth it).
  5966.  
  5967. Cliff Nadler                                         GO TEAM OS/2!
  5968. Systems Integration and Services                     Rockville, MD
  5969. IBM Federal Systems Company                PROFS: NADLER at WMAVM7
  5970.  
  5971. ----- OS2REXX CFORUM appended at 13:01:17 on 92/09/10 GMT (by ETTRITCH at TOROLAB5)
  5972. Subject: Registering External C functions
  5973. Ref:     None
  5974.  
  5975. I am attempting to register and use some external C functions.
  5976. The registration is successful, and when the functions are called
  5977. from within a REXX program the interpreter does find the code.
  5978. The only problem is that the arguments passed to the function contain
  5979. nonsensical data (for example the Argc value is in the millions).
  5980. Does anyone know what could be causing the problem?  Do I need to
  5981. set aside memory for these arguments?  I can't help feeling I've
  5982. missed a step somewhere, but I am following the documentation.
  5983. The functions being registered are in an EXE file, and the interpreter
  5984. is being started via RexxStart.
  5985. Any advice/suggestions would be welcome.
  5986.  
  5987. Sarah Ettritch
  5988.  
  5989. ----- OS2REXX CFORUM appended at 13:09:43 on 92/09/10 GMT (by FCOC079 at OS2CUST)
  5990. Subject: Registering External C functions
  5991. Ref: Append at 13:01:17 on 92/09/10 GMT (by ETTRITCH at TOROLAB5)
  5992.  
  5993. First, are your 'C' functions to be used as Rexx external functions?  If so,
  5994. your 'C' code must be compiled and linked as a DLL, the function entry points
  5995. must be EXPORTed (in a .DEF file), and be sure to use the _System linkage type
  5996. (most easily achieved by using the macro "RexxFunctionHandler").  For a good
  5997. example of how to implement an external function in 'C', look at the sample
  5998. 'C' code supplied in the 2.0 Toolkit under the Rexx samples directory
  5999. "\toolkt20\rexx\samples\rexxutil".
  6000.  
  6001. Or are these functions part of an EXE program which invokes interpreter via
  6002. RexxStart and wants its functions available to invoked exec?
  6003.  
  6004. Dave Boll
  6005.  
  6006. ----- OS2REXX CFORUM appended at 13:41:54 on 92/09/10 GMT (by SAMI3QU at OS2CUST)
  6007. Subject: Starting applications in the foreground
  6008.  
  6009. Using SysCreateObject or SysSetObjectData, is it possible to start an
  6010. application in the foreground?  Thanks.
  6011.  
  6012. Mark Thompson - Coal Services Corp.  St. Louis, MO
  6013.  
  6014. ----- OS2REXX CFORUM appended at 14:03:01 on 92/09/10 GMT (by FCOC079 at OS2CUST)
  6015. Subject: Rexx features
  6016.  
  6017. I'm not sure if the owners of Rexx graze in this forum, but if so, I thought
  6018. this would be an efficient way to get some (unsolicited) feedback to them.
  6019.  
  6020. I've been using Rexx on OS/2 for about two years and have found it to be
  6021. a great implementation of the language.  In the course of using it, a couple
  6022. of items have come to light as "deficiencies" in the implementation.  They
  6023. certainly aren't show stoppers, but to remedy them would increase the
  6024. usability of Rexx in OS/2 even more.
  6025.  
  6026. After having used MVS Rexx for a few years, it was great to see Rexx on OS/2.
  6027. In fact, there are lots of nice features in OS/2 Rexx which would be nice to
  6028. see on the other platforms (arbitrarily named queues, stream i/o, etc.).  But
  6029. after making extensive use of the Rexx stack service API in MVS (IRXSTK), I
  6030. was really surprised to find no queue/stack api in OS/2.  This limits the
  6031. ability of Rexx and non-Rexx programs to communicate multiple data items to
  6032. each other.  Without API access to the queue, stems are about the only choice.
  6033. But this is not an option if the non-Rexx program is not in the same process
  6034. as the Rexx program.  It's surprising to see such a powerful implementation
  6035. of Rexx fall short on such a basic and usable feature.
  6036. Also, as far as queue access via Rexx built-in functions is concerned, here
  6037. are a few enhancements which would be of great use:
  6038.  
  6039. 1) Have the "Queued()" function accept a queue name as an argument, therefore
  6040.    eliminating the need to use "RxQueue()" to set and reset the current queue.
  6041.    e.g. - "Say Queued('dataq')" would tell how many elements are on the queue
  6042.           called "data", "Say queued('session')" tells how many on the session
  6043.           queue, etc.
  6044.  
  6045. 2) Have the "LineIn()" and "LineOut()" functions be able to arbitrarily
  6046.    address a specific Rexx queue (also eliminating the need to set and reset
  6047.    the current Rexx queue with "RxQueue()"). For example, to copy one queue to
  6048.    another:
  6049.  
  6050.      Do Queued('dataq1')
  6051.        e = LineIn('queue:dataq1')
  6052.        Call LineOut 'queue:dataq2', e
  6053.        Call LineOut 'queue:dataq1',e
  6054.      End
  6055.  
  6056. Dave Boll
  6057.  
  6058. ----- OS2REXX CFORUM appended at 14:03:41 on 92/09/10 GMT (by CONT00 at LEXVMK)
  6059. Subject: Starting applications in the foreground
  6060. Ref:     Append at 13:41:54 on 92/09/10 GMT (by SAMI3QU at OS2CUST)
  6061.  
  6062. No - background only... It would steal the focus from the active window
  6063. otherwise.
  6064.  
  6065. Gregory Czaja, Lexington 8-545-3311  1992/09/10  10:02
  6066.  
  6067. ----- OS2REXX CFORUM appended at 15:08:38 on 92/09/10 GMT (by ETTRITCH at TOROLAB5)
  6068. Subject: Registering External C functions
  6069. Ref:     Append at 13:09:43 on 92/09/10 GMT (by FCOC079 at OS2CUST)
  6070.  
  6071. My 'C' functions are part of an EXE which invokes the interpreter
  6072. using RexxStart and wants its functions available to the invoked
  6073. exec.  Is there anything special that I have to do?  I will take
  6074. a look at the toolkit samples.
  6075.  
  6076. Sarah Ettritch
  6077.  
  6078. ----- OS2REXX CFORUM appended at 16:00:05 on 92/09/10 GMT (by FCOC079 at OS2CUST)
  6079. Subject: Registering External C functions
  6080. Ref: Append at 15:08:38 on 92/09/10 GMT (by ETTRITCH at TOROLAB5)
  6081.  
  6082. The 'C' functions should be declared with "_System" linkage.  I know that
  6083. Optlink (default in C-Set/2 I think) does give incorrect results (i.e. argc
  6084. large number, etc.).  If you use RexxFunctionHandler macro to declare function,
  6085. this specifies "_System" linkage for you.
  6086.  
  6087. Dave Boll
  6088.  
  6089. ----- OS2REXX CFORUM appended at 16:09:10 on 92/09/10 GMT (by ABLI001 at OS2CUST)
  6090. Subject: Concatenating strings in REXX
  6091. Ref: Append at 23:51:51 on 92/08/19 GMT (by SDETWEIL at DETVMIC4)
  6092.  
  6093. Why are you worried that implied abuttal will pose future problems?
  6094. It is part of SAA (see SC26-4358-3 page 11 and 19) and is in any textbook
  6095. that you pick up in a public library. In fact you probably won't see any usage
  6096. of || in textbooks.
  6097.  
  6098. ->Rich
  6099.  
  6100. ----- OS2REXX CFORUM appended at 19:28:42 on 92/09/10 GMT (by ETTRITCH at TOROLAB5)
  6101. Subject: Registering External C functions
  6102. Ref:     Append at 16:00:05 on 92/09/10 GMT (by FCOC079 at OS2CUST)
  6103.  
  6104. Dave, I used _system linkage and now everything works like a
  6105. charm.  Thanks for the help, you saved me a lot of time.  I never
  6106. would have known what the problem was if it hadn't been for you.
  6107. Great service!
  6108.  
  6109. Sarah Ettritch
  6110.  
  6111. ----- OS2REXX CFORUM appended at 20:02:27 on 92/09/10 GMT (by IL71329 at OS2CUST)
  6112. Subject: os/2 rexx date function
  6113.  
  6114. Is there any known REXX date function routines that when given a value,
  6115. it can tell you the day of week, day of year, compare 2 dates and return
  6116. differential, etc.
  6117.  
  6118. Becky Epping   Country Companies Ins.  Bloomington, IL
  6119.  
  6120. ----- OS2REXX CFORUM appended at 17:37:39 on 92/09/11 GMT (by NAAO3IY at OS2CUST)
  6121. Subject: os/2 rexx date function
  6122. Ref: Append at 20:02:27 on 92/09/10 GMT (by IL71329 at OS2CUST)
  6123.  
  6124. REXX has marvelous date support -- but for today's date only.
  6125.  
  6126. Razzafrazzum!
  6127.  
  6128. Howsomedever, here are algorithms to convert any date from 4713 B.C. through
  6129. 19,999 A.D. to the Julian Date, a serial number of days since January 1,
  6130. 4713 B.C.  (Dates B.C. are input and output as minus numbers.)  Either the
  6131. Julian Calendar (no relation to the Julian date -- they were merely both named,
  6132. by an unfortunately coincidence, after men named Julius) or the Gregorian
  6133. Calendar can be used.  Transition from the Julian Calendar to the Gregorian
  6134. Calendar defaults to Julian Date 2299161, skipping from October 5, 1582 to
  6135. October 15, but can be set to other dates, most commonly Julian Date 2361222,
  6136. skipping from September 3, 1752 to September 14, as in England and the
  6137. colonies.  (If you are only dealing with current dates, you can ignore all this
  6138. and just use the default.)
  6139.  
  6140. /* Convert a date from YMD to Julian */
  6141. Arg YMDY YMDM YMDD Trans;
  6142. If Trans = '' then Trans = 2299161;
  6143. AY = YMDY;
  6144. If YMDY < 0 then Y = YMDY + 4717; Else Y = YMDY + 4716;
  6145. If YMDM < 3 then do; M = YMDM + 12; Y = Y - 1; AY = AY - 1; End; Else M = YMDM;
  6146. D = (1461 * Y) % 4 + (153 * (M + 1)) % 5 + YMDD - 1524;
  6147. G = D + 2 - AY % 100 + AY % 400 - AY % 4000;
  6148. If G >= Trans then Return G; Else Return D;
  6149.  
  6150. /* Convert a date from Julian to YMD */
  6151. Arg J Trans;
  6152. If Trans = '' then Trans = 2299161;
  6153. If J < Trans then
  6154.   A = J;
  6155. Else do;
  6156.   AA = J - 1721120;
  6157.   AC = AA % 1460969; AB = 31 * AC; AA = AA - AC * 1460969;
  6158.   AC = AA % 146097; AB = AB + 3 * AC; AA = AA - AC * 146097;
  6159.   If AA = 146096 then AB = AB + 3; Else AB = AB + AA % 36524;
  6160.   A = J + (AB - 2);
  6161. End;
  6162. B = A + 1524; C = (20 * B - 2442) % 7305; D = 1461 * C % 4;
  6163. EE = B - D; E = 10000 * EE % 306001;
  6164. YMDD = EE - 306001 * E % 10000;
  6165. If E >= 14 then YMDM = E - 13; Else YMDM = E - 1;
  6166. If YMDM > 2 then Y = C - 4716; Else Y = C - 4715;
  6167. If Y < 1 then YMDY = Y - 1; Else YMDY = Y;
  6168. Return YMDY YMDM YMDD;
  6169.  
  6170. You can perform any date calculation by converting to the Julian Date,
  6171. performing straight arthmetic, and then converting back.  You can get the day
  6172. of the week by taking the remainder of the Julian Date divided by 7 and
  6173. assigning 0 = Monday through 6 = Sunday.
  6174.  
  6175. John Kennedy -- Hoechst Celanese, Bridgewater, NJ
  6176.  
  6177. ----- OS2REXX CFORUM appended at 04:12:33 on 92/09/14 GMT (by XXSHLW02 at TORVMCOP)
  6178. Subject: Hidden REXX Code
  6179. I have a requirement to implement an application startup that involves
  6180. an OS/2 (Easel) app, and WP and E-Mail (both of which are currently
  6181. Windows apps).  I am very pleased with the REXXUTIL functions to start
  6182. the WIN/OS2 sessions, but would also like to manage the complete e-mail
  6183. start up parameters and pass the user-name and password.  I will be able
  6184. to delete the information at logoff, but want to prevent disclosure by
  6185. placing the real Program Object in the hidden folder.  Unfortunately this
  6186. is for nought if the REXX exec which manipulates all this can be read by
  6187. a knowledgable user. I have had discussions at past OS/2 Tech Seminar's
  6188. on using the "translate" parameter to pre-parse the exec (exec-name //T)
  6189. and also had the impression that if I was willing to manage re-compiles
  6190. when REXX maintenance was applied that there was a way to actually remove
  6191. the REXX source from the file (if the EAs which store the parsed version
  6192. were left intact).  I have been trying this with no luck.  Is this
  6193. possible (if not recommended!).
  6194. I understand that the parsed code is not intended to be a defined
  6195. interface of REXX, and that code changes could force a re-compile,
  6196. but we will be managing software levels on the client machines
  6197. (several hundred) carefully and can live with that.  Is there a date &
  6198. time stamp conflict that I must thwart?  How does the interpreter decide
  6199. whether to use the pre-compiled version?
  6200.  My alternative is to get REALLLY dirty with SOM interfaces (I presume)
  6201. that provide equivalent interfaces to the
  6202. WorkPlace shell, and the resulting product would be too complex for
  6203. the customer to maintain.  Any suggestions on how I can securely
  6204. distribute an exec ( not allow the source to be read and modified )?
  6205.  
  6206. Bruce Popham (SHL Systemhouse - Wpg)
  6207.  
  6208. ----- OS2REXX CFORUM appended at 16:31:34 on 92/09/14 GMT (by PGM$298 at ATLVM2)
  6209. Subject: Executing a C program from a DEATCHED REXX Program
  6210. Ref:     Append at 17:16:48 on 92/07/02 GMT (by 64932769 at TOROHON1)
  6211.  
  6212. I was just browsing this forum and saw your append.  This may be too
  6213. late to be of help to you but maybe others are having the same
  6214. difficulty.  I have seen the exact symptoms you described.  The
  6215. resolution is to change the application type of your C program to
  6216. WINDOWCOMPAT.
  6217.  
  6218. Clark, S. W. (Steve)
  6219.  
  6220. ----- OS2REXX CFORUM appended at 17:03:21 on 92/09/14 GMT (by PRICESG at GDLVM7)
  6221. Subject: Rexx features
  6222. Ref:     Append at 14:03:01 on 92/09/10 GMT (by FCOC079 at OS2CUST)
  6223.  
  6224. Yes, Dave, we do monitor this forum for suggestions, problems, etc. As
  6225. you have noticed, though, we're not always very prompt!  Sorry.  Your
  6226. queuing suggestions are now "on the list" (actually, they were already
  6227. there, but now they have more priority placed on them).  The contents
  6228. of future release of REXX in OS/2 are worked out between the OS/2
  6229. system folks and REXX Development.
  6230.  
  6231. Thanks for the comments.  Feedback is always welcome.
  6232.  
  6233. Steve (merrily we graze along) Price    SAA REXX Development
  6234.  
  6235. ----- OS2REXX CFORUM appended at 19:52:21 on 92/09/14 GMT (by CONT00 at LEXVMK)
  6236. Subject: Hidden REXX Code
  6237. Ref:     Append at 04:12:33 on 92/09/14 GMT (by XXSHLW02 at TORVMCOP)
  6238.  
  6239. If you consider some additional maintenance overhead, I'd suggest you
  6240. look at a little known but very powerful feature (available since 1.3.)
  6241. of REXX: Macro Spaces.
  6242. This is the place the interpreter keeps the tokenized program after
  6243. loading it into memory. What makes the MacroSpace (let's call it MS for
  6244. a moment :-) concept very attractive, is the set of programming interfaces.
  6245. The basic features are:
  6246. - you can load a file into the MS - it will be tokenized and kept there
  6247.   available for every program which will issue a (REXX) call for a name
  6248.   under which it was loaded (it may be different than the original file
  6249.   name). Since you can specify an "order" for such macro, you can force
  6250.   all programs to use the MS-version instead of the real file stored
  6251.   on your disk.
  6252. - the current content of the MS can be "saved" into a library file.
  6253.   The library file equals basically to what you see in extended attributes
  6254.   but it can be easily moved to another machine (as long as they are on
  6255.   the same REXX level) and THIS is YOUR chance !
  6256.   The content of the library file is not easy readable - if you put some
  6257.   encryption on your password data, they will be safe.
  6258. - you can "load" the content of the library file into the MS having all
  6259.   your programs ready to run instantly.
  6260. - in addition you have API for querying the MS and deleting from MS.
  6261.  
  6262. So, all you need is a small loader program which will load saved library
  6263. file and call he first program...
  6264. The APIs are available in REXXUTIL from REXX or directly from C.
  6265. Happy REXXing !
  6266.  
  6267. Gregory Czaja, Lexington 8-545-3311  1992/09/14  15:33
  6268.  
  6269. ----- OS2REXX CFORUM appended at 22:52:58 on 92/09/14 GMT (by XXNOVA24 at TORVMCOP)
  6270. Subject: Hidden REXX Code
  6271. Ref:     Append at 19:52:21 on 92/09/14 GMT (by CONT00 at LEXVMK)
  6272.  
  6273. Gregory,
  6274. Just the old request again,
  6275.     You don't happened to have a small example handy to teach us,
  6276. do you?
  6277.  
  6278. Geza Szivos
  6279. NOVACOR Chemicals (403)-290-6583
  6280. NHO-32 801-7th Ave Calgary, Alberta, CANADA  T2P 2N6
  6281.  
  6282. ----- OS2REXX CFORUM appended at 13:50:29 on 92/09/15 GMT (by FCOC079 at OS2CUST)
  6283. Subject: Rexx features
  6284. Ref: Append at 17:03:21 on 92/09/14 GMT (by PRICESG at GDLVM7)
  6285.  
  6286. Thanks for the response Steve.  It's good to see that the items were already
  6287. on a list.
  6288.  
  6289. Dave Boll
  6290.  
  6291. ----- OS2REXX CFORUM appended at 16:17:58 on 92/09/15 GMT (by CONT00 at LEXVMK)
  6292. Subject: Hidden REXX Code
  6293. Ref:     Append at 22:52:58 on 92/09/14 GMT (by XXNOVA24 at TORVMCOP)
  6294.  
  6295. No, I didn't, but I kludged one for you :-)... Feel free !
  6296.  
  6297. Note: REXX20 fixes needed (dated at least June 1992 !)
  6298.  
  6299. Gregory Czaja, Lexington 8-545-3311  1992/09/15  12:13
  6300.  
  6301. /* <------------------------- cut here -----------------------------> */
  6302. /*** REXXTEST.CMD ****************************************************/
  6303. /*** Rexx Exec for Testing REXXXUTIL functions   -   By Greg Czaja ***/
  6304. /*** based on RXTEST.CMD for RXUTILS             -   By Tom Rogers ***/
  6305. /*********************************************************************/
  6306. Parse Arg arg
  6307. if arg='MACRO' then do
  6308.   Parse Source . . my_name .
  6309.   say  /* note: the program name is the macro name, not the original name ! */
  6310.   say 'Hey, we are executing 'my_name' from the macrospace.'; say
  6311.   say 'Press any key to exit...'
  6312.   call SysGetKey 'NOECHO'
  6313.   exit
  6314. end
  6315.  
  6316. Call RxFuncAdd 'SysLoadFuncs', 'REXXUTIL', 'SYSLOADFUNCS'
  6317. Call SysLoadFuncs;
  6318.  
  6319. /**********************************************************************
  6320. ***** The following section tests RexxUtil functions dealing     ******
  6321. ***** with the REXX Macrospace.                                  ******
  6322. **********************************************************************/
  6323. Call SysCls
  6324.   say 'Testing erasing all macros from the macrospace...'
  6325.   say SysClearRexxMacroSpace()
  6326.   say; call SysGetKey 'NOECHO'
  6327.   call SysCls; say
  6328.   say 'Testing loading REXXTEST.CMD into macrospace as REXX2 !'
  6329.   say SysAddRexxMacro('REXX2', 'REXXTEST.CMD', 'BEFORE')
  6330.   say; call SysGetKey 'NOECHO'
  6331.   call SysCls; say
  6332.   say 'Testing saving REXX2 macro as REXX2.MAC...'
  6333.   '@ERASE REXX2.MAC';
  6334.   say SysSaveRexxMacroSpace('REXX2.MAC')
  6335.   say; call SysGetKey 'NOECHO'
  6336.   call SysCls; say
  6337.   say 'Testing dropping REXX2 macro...'
  6338.   say SysDropRexxMacro('REXX2')
  6339.   say; call SysGetKey 'NOECHO'
  6340.   call SysCls; say
  6341.   say 'Testing loading REXX2 from REXX2.MAC...'
  6342.   say SysLoadRexxMacroSPace('REXX2.MAC')
  6343.   say; call SysGetKey 'NOECHO'
  6344.   call SysCls; say
  6345.   say 'Running REXX2 (from MacroSpace)...'
  6346.   call REXX2 'MACRO'
  6347.   say; say 'You are back to running REXXTEST.CMD now!'
  6348.   say; call SysGetKey 'NOECHO'
  6349.   call SysCls; say
  6350.   say 'Testing changing position of REXXTEST...'
  6351.   say SysReorderRexxMacro('REXX2', 'AFTER')
  6352.   say; call SysGetKey 'NOECHO'
  6353.   call SysCls; say
  6354.   say 'Testing query and order by seeing if REXX2 macro exists...'
  6355.   say SysQueryRexxMacro('REXX2')
  6356.   say; call SysGetKey 'NOECHO'
  6357. exit
  6358.  
  6359. /* <------------------------- cut here -----------------------------> */
  6360.  
  6361. ----- OS2REXX CFORUM appended at 23:40:08 on 92/09/15 GMT (by AAAF0CY at OS2CUST)
  6362. Subject: Using SysCreateObject to set DOS_VERSION
  6363. Ref: Append at 15:29:22 on 92/08/21 GMT (by NBLKCY0 at OS2CUST)
  6364.  
  6365. Between DOS_VERSION items, you need to insert a line feed character. For
  6366. example to set DOS_VERSION for ABC.EXE and XYZ.EXE you would use the REXX
  6367. string:
  6368. 'SET DOS_VERSION=C:\ABC.EXE,4,0,255<XX>C:\XYZ.EXE,4,0,255'
  6369. Where the <XX> is entered by holding the ALT key and pressing 10 on the keypad
  6370. to create the linefeed character.
  6371. A tip I found helpful when testing this is to intentially put an error in the
  6372. setup string information in the SysCreateObject call, then when you make the
  6373. call, the dialog box shows up that tells you there is an error in the setup and
  6374. allows you to view the settings, then you can check them for accuracy.
  6375.  
  6376. Jim Sauber, MN Mutual
  6377.  
  6378. ----- OS2REXX CFORUM appended at 03:43:01 on 92/09/16 GMT (by XXSHLW02 at TORVMCOP)
  6379. Subject: Hidden REXX Code
  6380. Ref:     Append at 16:17:58 on 92/09/15 GMT (by CONT00 at LEXVMK)
  6381.  
  6382. I appreciate the samples, as my initial efforts at looking at the
  6383. MacroSpace API's led me to conclude that the creation of the macro
  6384. space (and loading of it later) would require "C" routines, which the
  6385. also would prefer to avoid.. However...(sorry about this). In being so
  6386. responsive to ever increasing demands for new function there is quite a
  6387. mix-up in the REXX20 package of DLLs.  I initially started with a set of
  6388. enhancements that had some documentation on WPS functions, but was
  6389. missing calls like SysSetObjectData (? from memory).. I found an even
  6390. more current version of the REXX20 package, but it does not seem to
  6391. have the MacroSpace calls.. I will call Atlanta now and try and get the
  6392. most current code from there.. Will update you on status.
  6393.  
  6394. Thanks a lot for all the assistance!!
  6395. Note: the module dates I am running are:
  6396.    rexx     DLL   248192   7-08-92   4:04p
  6397.    rexxapi  DLL    33351   7-01-92   4:29p
  6398.    rexxinit DLL     1468   6-30-92   9:49a
  6399.    rexxutil DLL    31321   7-01-92   4:29p
  6400.  
  6401. Bruce Popham (SHL Systemhouse - Wpg)
  6402.  
  6403. ----- OS2REXX CFORUM appended at 12:23:41 on 92/09/16 GMT (by CONT00 at LEXVMK)
  6404. Subject: Hidden REXX Code
  6405. Ref:     Append at 03:43:01 on 92/09/16 GMT (by XXSHLW02 at TORVMCOP)
  6406.  
  6407. Ooops ! Sorry for the confusion, I thought the MacroSpace functions were
  6408. in REXXUTIL dated on/after June 16, 1992. If they aren't there, they will
  6409. be (probably) in the service pack... Rick McGuire would be more competent
  6410. person.
  6411. You have still the option of using the C APIs - the 2.0 toolkit has a few
  6412. samples, it is not difficult.
  6413.  
  6414. Gregory Czaja, Lexington 8-545-3311  1992/09/16  08:10
  6415.  
  6416. ----- OS2REXX CFORUM appended at 14:06:55 on 92/09/16 GMT (by XXNOVA24 at TORVMCOP)
  6417. Subject: Hidden REXX Code
  6418. Ref:     Append at 16:17:58 on 92/09/15 GMT (by CONT00 at LEXVMK)
  6419.  
  6420. Thanks, Gregory,
  6421. but my files are dated:
  6422. Directory of C:\OS2\DLL
  6423.  
  6424. 7-08-92   4:04p    248192           0  REXX.DLL
  6425. 7-01-92   4:29p     33351           0  REXXAPI.DLL
  6426. 6-30-92   9:49a      1468           0  REXXINIT.DLL
  6427. 7-01-92   4:29p     31321           0  REXXUTIL.DLL
  6428.  
  6429. and when I try to execute the TEXXTest,
  6430.  
  6431. Testing erasing all macros from the macrospace...
  6432.     25 +++   Say SysClearRexxMacroSpace();
  6433. REX0043: Error 43 running D:\tmp\REXXTest.CMD, line 25: Routine not found
  6434.  
  6435. message is what I get.
  6436.  
  6437. Maybe I have to wait for the Service Pack.(?)
  6438.  
  6439. Geza Szivos
  6440. NOVACOR Chemicals (403)-290-6583
  6441. NHO-32 801-7th Ave Calgary, Alberta, CANADA  T2P 2N6
  6442.  
  6443. ----- OS2REXX CFORUM appended at 15:11:54 on 92/09/16 GMT (by XXSHLW02 at TORVMCOP)
  6444. Subject: Hidden REXX Code
  6445. Ref:     Append at 12:23:41 on 92/09/16 GMT (by CONT00 at LEXVMK)
  6446.  
  6447. I have essentially the same problem as documented in append 311 by my
  6448. compatriat at Nova.. As I understand it, the service pack is still
  6449. some time away (3-4 weeks at best?).  Without muddying the waters
  6450. and releasing a third copy of the REXXUTIL since GA is it possible
  6451. to gain access on a restricted basis (The customer is wanting
  6452. to roll out the application asap, and would not be willing to
  6453. wait that long). The probable result will be that we leave the
  6454. security processing visible (it is obscure at best, and only would allow
  6455. a user to find out his own mail password (something most users know
  6456. anyway..).  Thanks again for your help, The knowledge that we can deliver
  6457. the required function without another "C" module for the customer to
  6458. own is great!
  6459.  
  6460. Bruce Popham (SHL Systemhouse - Wpg)
  6461.  
  6462. ----- OS2REXX CFORUM appended at 15:39:16 on 92/09/16 GMT (by CONT00 at LEXVMK)
  6463. Subject: Hidden REXX Code
  6464. Ref:     Append at 14:06:55 on 92/09/16 GMT (by XXNOVA24 at TORVMCOP)
  6465.  
  6466. I'm afraid, you have (to wait)... Sorry for the confusion !-(
  6467. I decided not to remove the sample - you could use it when you get the
  6468. updated REXXUTIL.DLL.
  6469.  
  6470. Gregory Czaja, Lexington 8-545-3311  1992/09/16  11:37
  6471.  
  6472. ----- OS2REXX CFORUM appended at 18:49:54 on 92/09/16 GMT (by PPBKR at OS2CUST)
  6473. Subject: Using SysCreateObject to set NETWARE_RESOURCES
  6474.  
  6475. The install program for OS/2 Netware Requester adds the DOS setting
  6476. "NETWARE_RESOURCES" to the list of available settings in the DOS
  6477. SETTINGS panel. It's value can be NONE, PRIVATE, or GLOBAL.
  6478.  
  6479. I would like to use SysCreateObject to change it's value.  For example,
  6480. I have a REXX program that will add a DOS program object to a folder and
  6481. I am successfully modifying several of it's DOS settings using
  6482. SysCreateObject.  However, I haven't been able to change the
  6483. NETWARE_RESOURCES variable.
  6484.  
  6485. The setup string that I'm using looks something like this:
  6486.  
  6487.  SET NETWARE_RESOURCES=GLOBAL;
  6488.  
  6489. I've also tried SET NETWARE_RESOURCES=2; (using a number didn't work either).
  6490.  
  6491. Has anyone else tried to modify this setting via SysCreateObject? If so, how?
  6492. Thanks in advance for your assistance!
  6493.  
  6494. BK Rogers  Phillips Petroleum
  6495.  
  6496. ----- OS2REXX CFORUM appended at 20:08:47 on 92/09/16 GMT (by CONT00 at LEXVMK)
  6497. Subject: Using SysCreateObject to set NETWARE_RESOURCES
  6498. Ref:     Append at 18:49:54 on 92/09/16 GMT (by PPBKR at OS2CUST)
  6499.  
  6500. This may be similar to the problems with another DOS setting:
  6501. VIDEO_MODE_RESTRICTION, which requires the value to be padded to the right
  6502. with blanks to be exactly 15 characters.
  6503. You may try 7 since PRIVATE is that long, i.e.
  6504. SET NETWARE_RESOURCES=GLOBAL ;   <-- extra blank.
  6505.  
  6506. If you display the DOS_SETTINGS for NETWARE_RESOURCES, can you guestimate
  6507. how many characters the shadowing takes in the drop-down combobox ?
  6508. (sorry, dont't have NETWARE installed myself...)
  6509.  
  6510. Gregory Czaja, Lexington 8-545-3311  1992/09/16  15:56
  6511.  
  6512. ----- OS2REXX CFORUM appended at 21:50:37 on 92/09/16 GMT (by PPBKR at OS2CUST)
  6513. Subject: Using SysCreateObject to set NETWARE_RESOURCES
  6514.  
  6515. Padding the value to 7 characters did the trick. All valid selections worked:
  6516.  
  6517.   SET NETWARE_RESOURCES=NONE   ;
  6518.   SET NETWARE_RESOURCES=PRIVATE;
  6519.   SET NETWARE_RESOURCES=GLOBAL ;
  6520.  
  6521. Thanks for the info!
  6522.  
  6523. BK Rogers  Phillips Petroleum
  6524.  
  6525. ----- OS2REXX CFORUM appended at 12:48:28 on 92/09/17 GMT (by MCGUIRE at GDLVM7)
  6526. Subject: Hidden REXX Code
  6527. Ref:     Append at 12:23:41 on 92/09/16 GMT (by CONT00 at LEXVMK)
  6528.  
  6529. Those extra functions are not going to be part of a service pack, but are
  6530. rather candidates for a future release.
  6531.  
  6532. Rick McGuire - SAA Rexx Development, Endicott
  6533.  
  6534. ----- OS2REXX CFORUM appended at 13:57:59 on 92/09/17 GMT (by IL69655 at OS2CUST)
  6535. Subject: Beginner's Questions
  6536.  
  6537. I am trying to write my first REXX procedure and am having
  6538. great difficulties with the following:
  6539.  
  6540. 1. It seems that REXX does not recognize the old test
  6541.        IF EXIST filename THEN.... Does anyone know of a
  6542.    way to test for the existense of a file?
  6543.  
  6544. 2. It also seems that the old GOTO label  statement does
  6545.    not work in REXX (error message says label cannot be found).
  6546.    I used the SIGNAL function instead for branching to a
  6547.    label. This works- but is this the correct instruction
  6548.    to use in REXX?
  6549.  
  6550.    Any help would be greatly appreciated.
  6551.  
  6552.    John Salientes, The World Bank, Wash.DC
  6553.  
  6554. John Salientes, The World Bank, Wash.DC
  6555.  
  6556. ----- OS2REXX CFORUM appended at 14:22:00 on 92/09/17 GMT (by MRTOM at YKTVMV)
  6557. Subject: Beginner's Questions
  6558. Ref:     Append at 13:57:59 on 92/09/17 GMT (by IL69655 at OS2CUST)
  6559.  
  6560. 1.  if stream(file, 'C', 'QUERY EXISTS')  <> '' then /* file exists */
  6561.  
  6562. 2.  Signal will work, but if your program needs signal your program
  6563.     probably needs to be rewritten.  Signal can be avoided the majority
  6564.     of the time.
  6565.  
  6566. Tom
  6567.  
  6568. ----- OS2REXX CFORUM appended at 15:23:20 on 92/09/17 GMT (by GBFORNEY at WASVMIC5)
  6569. Subject: Beginner's Questions
  6570. Ref:     Append at 13:57:59 on 92/09/17 GMT (by IL69655 at OS2CUST)
  6571.  
  6572. 1) Use the Stream command "Query Exists" to inquire if a file is
  6573. present:
  6574.  
  6575. If Stream(filen,'C','Query Exists') = '' Then
  6576.    Do
  6577.    /* File is missing */
  6578.    End
  6579. Else
  6580.    Do
  6581.    /* File is available */
  6582.    End
  6583.  
  6584. 2) Yes, Signal is the right thing to use in place of GOTO. However
  6585. Rexx was designed to strongly discourage any use of arbitrary
  6586. branching at all.
  6587.  
  6588. Greg Forney  bigred@vnet.ibm.com
  6589.  
  6590. ----- OS2REXX CFORUM appended at 16:43:25 on 92/09/21 GMT (by ABLI001 at OS2CUST)
  6591. Subject: commands in PM mode
  6592.  
  6593. Here's a quickie. Try creating a REXX .cmd file:
  6594.   /* */
  6595.   'cmd'
  6596. Nothing useful about such a 'batch' file you say?
  6597. Start a PM session (use desktop if you want) by typing
  6598.   start pmrexx xx       (where xx is the name of your .cmd file)
  6599. and a windowed command session comes up.
  6600. What is interesting is that you can run fullscreen commands under it
  6601. and then scroll backwards through the output. (How does it capture the
  6602. output? Wish I could write an APPC program to do it from CICS).
  6603. It is limited in ways though, e.g. it doesn't understand ANSI in the
  6604. prompt so you may want to change it in your .cmd file
  6605.  
  6606. ->Rich Corbett; ABC Liquors, Inc., Orlando, FL              (NASPA: CORBRIC7)
  6607.  
  6608. ----- OS2REXX CFORUM appended at 18:02:02 on 92/09/21 GMT (by XXNOVA24 at TORVMCOP)
  6609. Subject: Desktop recreation.
  6610. Gregory,
  6611.    Where is the REXX file to recreate all the objects?
  6612. I can't recall the name.
  6613. Actally I'd like to get the OBJECTID values.
  6614. Thanks,
  6615.  
  6616. Geza Szivos
  6617. NOVACOR Chemicals (403)-290-6583
  6618. NHO-32 801-7th Ave Calgary, Alberta, CANADA  T2P 2N6
  6619.  
  6620. ----- OS2REXX CFORUM appended at 19:08:23 on 92/09/21 GMT (by CONT00 at LEXVMK)
  6621. Subject: Desktop recreation.
  6622. Ref:     Append at 18:02:02 on 92/09/21 GMT (by XXNOVA24 at TORVMCOP)
  6623.  
  6624. INI.RC is located in \OS2 directory on your boot drive and contains all
  6625. standard objects sans OBJECTIDs.
  6626. The program which recreates those is located on CServe, IBMOS2 forum,
  6627. library 8 (REXX), file name RECREA.CMD (it's free :-).
  6628.  
  6629. BTW: to get all currently defined OBJECTIDs use:
  6630.      Call SysIni 'USER', 'PM_Workplace:Location', 'All:', 'objectids.';
  6631. stem objectids. will contain them all... Enjoy !
  6632.  
  6633. Gregory Czaja, Lexington 8-545-3311  1992/09/21  15:04
  6634.  
  6635. ----- OS2REXX CFORUM appended at 19:38:27 on 92/09/21 GMT (by XXNOVA24 at TORVMCOP)
  6636. Subject: Desktop recreation.
  6637. Ref:     Append at 19:08:23 on 92/09/21 GMT (by CONT00 at LEXVMK)
  6638.  
  6639. Thanks, Gregory, but:
  6640. I wrote s small program:
  6641.  
  6642. /* Greg */
  6643.      Call SysIni 'USER', 'PM_Workplace:Location', 'All:', 'objectids.';
  6644.  
  6645. say objectids.0
  6646.  
  6647. do i=0 to i=objectids.0
  6648.    say objectids.i
  6649. end;
  6650.  
  6651. My output is 67 twice.
  6652. What do I do wrong again?
  6653.  
  6654. Geza Szivos
  6655. NOVACOR Chemicals (403)-290-6583
  6656. NHO-32 801-7th Ave Calgary, Alberta, CANADA  T2P 2N6
  6657.  
  6658. ----- OS2REXX CFORUM appended at 19:57:15 on 92/09/21 GMT (by PPBKR at OS2CUST)
  6659. Subject: Desktop recreation.
  6660.  
  6661. Geza,
  6662.  
  6663. Your DO loop needs some work> Correct:  do i=0 to objectids.0
  6664.                                   NOT:  do i=0 to i=objectids.0
  6665. Try this:
  6666.  
  6667. Call SysIni 'USER', 'PM_Workplace:Location', 'All:', 'objectids.';
  6668.  
  6669. say objectids.0
  6670.  
  6671. do i=1 to objectids.0
  6672.    say objectids.i
  6673. end;
  6674.  
  6675. BK Rogers  Phillips Petroleum
  6676.  
  6677. ----- OS2REXX CFORUM appended at 20:16:53 on 92/09/21 GMT (by IL32772 at OS2CUST)
  6678. Subject: Com Mgr control
  6679.  
  6680. Can I control/start a 3270 or 5250 session with rexx? The Programmable Configur
  6681. ation Reference provides information to configure Com Mgr with rexx but not
  6682. mange sessions.  The Com Mgr System Management Programming reference indicates
  6683. using C or other languages to establish and monitor sessions, etc.  Can Rexx be
  6684.  use for this? I assume the answer is no since it's not listed as a language.
  6685.  
  6686. Randy Cairns
  6687.  
  6688. ----- OS2REXX CFORUM appended at 20:33:13 on 92/09/21 GMT (by XXNOVA24 at TORVMCOP)
  6689. Subject: Desktop recreation.
  6690. Ref:     Append at 19:57:15 on 92/09/21 GMT (by PPBKR at OS2CUST)
  6691.  
  6692. Thanks, BK,
  6693. I knew I was missing someting.
  6694.  
  6695. Geza Szivos
  6696. NOVACOR Chemicals (403)-290-6583
  6697. NHO-32 801-7th Ave Calgary, Alberta, CANADA  T2P 2N6
  6698.  
  6699. ----- OS2REXX CFORUM appended at 22:41:24 on 92/09/21 GMT (by NAAO3IY at OS2CUST)
  6700. Subject: Com Mgr control
  6701. Ref: Append at 20:16:53 on 92/09/21 GMT (by IL32772 at OS2CUST)
  6702.  
  6703. See \CMLIB\RXHLLAPI.DOC
  6704.  
  6705. John Kennedy -- Hoechst Celanese, Bridgewater, NJ
  6706.  
  6707. ----- OS2REXX CFORUM appended at 02:04:20 on 92/09/22 GMT (by SDETWEIL at DETVMIC4)
  6708. Subject: commands in PM mode
  6709. Ref:     Append at 16:43:25 on 92/09/21 GMT (by ABLI001 at OS2CUST)
  6710.  
  6711. How does it do it? It redirects STDOUT/ERR pack to PMREXX which
  6712. draws it in its window.. nothing particularly hard. Oh, the source
  6713. for PMREXX IS in the toolkit samples..
  6714.  
  6715. There IS a APPC pgm that does this in the IBMEWS software, AREXEC
  6716.  
  6717. Sam
  6718.  
  6719. ----- OS2REXX CFORUM appended at 20:14:37 on 92/09/23 GMT (by ABLI001 at OS2CUST)
  6720. Subject: commands in PM mode
  6721. Ref: Append at 02:04:20 on 92/09/22 GMT (by SDETWEIL at DETVMIC4)
  6722.  
  6723. Thanks for the info.!
  6724. By the way, I don't have access to the toolkit since we are an "end user" shop
  6725. and don't pay those prices for things which aren't "necessary" for users.
  6726.  The version of AREXEC that I downloaded (from another BBS) didn't have source;
  6727.  and didn't allow any input, so it may not be possible to redirect STDIN in all
  6728.  cases. (?? is the source available?)
  6729.  
  6730. ->Rich Corbett; ABC Liquors, Inc., Orlando, FL              (NASPA: CORBRIC7)
  6731.  
  6732. ----- OS2REXX CFORUM appended at 16:12:54 on 92/09/25 GMT (by STHOWELL at DALHQIC2)
  6733. Subject: Passing a stem variable to an external function . . .
  6734.  
  6735. In the following REXX.cmd, you can pass the stem variable (x.)
  6736. to an internal procedure; however, if I try to do the same
  6737. thing except to an external procedure, it does not work. Am
  6738. I doing something wrong, or is this a limitation of REXX?
  6739. -----------------------------------------
  6740. x.1=1; x.2=2; x.3=3
  6741. call test
  6742. say x.4 x.5 x.6
  6743. exit
  6744.  
  6745. test: procedure expose x.
  6746. say x.1 x.2 x.3
  6747. x.4=4; x.5=5; x.6=6
  6748. return
  6749. -----------------------------------------
  6750. result: 1 2 3
  6751.         4 5 6
  6752.  
  6753. Thanks,
  6754. Steve Howell
  6755.  
  6756. ----- OS2REXX CFORUM appended at 19:12:31 on 92/09/25 GMT (by XXMUTL27 at TORVMCOP)
  6757. Subject: Starting objects serially
  6758.  
  6759. I'd like to write a Rexx program to:
  6760.   i) connect to a network drive
  6761.  ii) create an object to start a program (winword.exe) from the
  6762.      network drive with specific DOS Settings
  6763. iii) open the object (i.e. invoke winword)
  6764.  iv) when done with application (exits winword) then disconnect from
  6765.      the network drive.
  6766.  
  6767. I've managed to do the first three without any difficulty, its the
  6768. fourth step that's causing me problems.  When using the OPEN=DEFAULT
  6769. setting with SysCreateObject, the program is invoked as another task.
  6770. What I want is to return to my Rexx script only when the application
  6771. is finished so that I can release the resource.  This is important
  6772. because we are using a counter on the server to limit resource usage.
  6773. For example, we have six WinWord licences, four Excel licences and
  6774. one Lotus 1-2-3 license for twelve users.  Therefore the resources need
  6775. to be released when the user is done with them.  Hence, I need to
  6776. serialize the open process.  Any help would be appreciated.
  6777.  
  6778. Erik Vander Ahe                            The Mutual Group
  6779.                                            Waterloo, Ontario
  6780.  
  6781. ----- OS2REXX CFORUM appended at 21:01:05 on 92/09/25 GMT (by NAAO3IY at HONE85)
  6782. Subject: VREXX and OOREXX
  6783.  
  6784. Are these two the same thing, or is VREXX just PM goodies for
  6785. current REXX, with OOREXX a new REXX yet to come?
  6786.  
  6787. ----- OS2REXX CFORUM appended at 23:24:39 on 92/09/25 GMT (by IL11901 at OS2CUST)
  6788. Subject: commands in PM mode
  6789. Ref: Append at 16:43:25 on 92/09/21 GMT (by ABLI001 at OS2CUST)
  6790.  
  6791.  (no text entered)
  6792.  
  6793. Steve Dacek - Soft & GUI Inc
  6794.  
  6795. ----- OS2REXX CFORUM appended at 23:26:18 on 92/09/25 GMT (by IL11901 at OS2CUST)
  6796. Subject: commands in PM mode
  6797. Ref: Append at 16:43:25 on 92/09/21 GMT (by ABLI001 at OS2CUST)
  6798.  
  6799. Please check out CommandLine 2.0.  It's a hotkey,
  6800. PM based prompt and app. launcher.
  6801.  
  6802. Steve Dacek - Soft & GUI Inc
  6803.  
  6804. ----- OS2REXX CFORUM appended at 18:39:28 on 92/09/27 GMT (by PRICESG at GDLVM7)
  6805. Subject: VREXX and OOREXX
  6806. Ref:     Append at 21:01:05 on 92/09/25 GMT (by NAAO3IY at HONE85)
  6807.  
  6808. Different things.  VREXX is an extension package for today's REXX.  OO
  6809. REXX is a working name for a major step in the evolution of the
  6810. language.  VREXX is available now as an unsupported package in the
  6811. Employee Written Software program.  OO REXX is at best many months
  6812. away, and has not been formally announced (which means it might never
  6813. see the light of day if some major problem arises).  OO REXX is being
  6814. worked on by REXX Development and some other people around IBM with
  6815. special skills.
  6816.  
  6817. Steve Price        IBM SAA REXX Development
  6818.  
  6819. ----- OS2REXX CFORUM appended at 13:36:43 on 92/09/28 GMT (by PERSHNG at YKTVMH)
  6820. Subject: Passing a stem variable to an external function . . .
  6821. Ref:     Append at 16:12:54 on 92/09/25 GMT (by STHOWELL at DALHQIC2)
  6822.  
  6823. It's a "limitation" of REXX -- EXPOSE doesn't work across external calls.
  6824.  
  6825. John A. Pershing Jr.
  6826.  
  6827. ----- OS2REXX CFORUM appended at 19:30:29 on 92/09/28 GMT (by AYP1Q01 at OS2CUST)
  6828. Subject: Starting objects serially
  6829. Ref: Append at 19:12:31 on 92/09/25 GMT (by XXMUTL27 at TORVMCOP)
  6830.  
  6831. Yes, I am interested in this, too, for exactly the same reasons.  Lacking the
  6832. ability to serially execute these functions, is there any way to monitor the
  6833. status of other tasks (in order to set up dependencies)?
  6834.  
  6835. Any input, comments, groundswell of support, or piqued interest would be
  6836. appreciated.
  6837.  
  6838. Steve Bassler, Allegheny Power
  6839.  
  6840. ----- OS2REXX CFORUM appended at 19:37:18 on 92/09/28 GMT (by AYP1Q01 at OS2CUST)
  6841. Subject: Starting objects serially
  6842. Ref: Append at 19:12:31 on 92/09/25 GMT (by XXMUTL27 at TORVMCOP)
  6843.  
  6844. Yes, I am interested in this, too, for exactly the same reasons.  If it is
  6845. indeed impossible to execute these functions serially, is there any way to
  6846. monitor the status of other tasks, for the purpose of setting up dependencies?
  6847.  
  6848. Any input, comments, groundswell of support, or piqued interest would be
  6849. appreciated.  Thanks.
  6850.  
  6851. Steve Bassler, Allegheny Power
  6852.  
  6853. ----- OS2REXX CFORUM appended at 20:08:33 on 92/09/28 GMT (by IL48722 at OS2CUST)
  6854. Subject: CPI-C functions for REXX
  6855.  
  6856. Anybody know where I can find a set of CPI-C functions for REXX??
  6857.  
  6858. I want to write a fairly simple-minded APPC requester to test a
  6859. mainframe application I'm writing, but I'd rather not have to write
  6860. it in C if I can avoid it (for one thing, the C compiler is not
  6861. cheap, for another, writing C is not my idea of a good time).
  6862.  
  6863. A REXX CPI-C package would be ideal for what I have in mind.
  6864.  
  6865. Any leads would be very much appreciated.
  6866.  
  6867. Bob Beilstein, Manugistics, Inc.  (315) 458-0723
  6868.  
  6869. ----- OS2REXX CFORUM appended at 20:59:45 on 92/09/28 GMT (by PRICESG at GDLVM7)
  6870. Subject: CPI-C functions for REXX
  6871. Ref:     Append at 20:08:33 on 92/09/28 GMT (by IL48722 at OS2CUST)
  6872.  
  6873. Such a deal I have for you....Extended Services provides a CPI-C to
  6874. REXX interface.  You initialize it with the command CPICREXX and
  6875. then you can do it the same as on the other SAA platforms:
  6876.    ADDRESS CPIC 'CMINIT.....'
  6877. I'm not very familiar with the actual coding of the CPIC verbs.  There
  6878. are some sample programs to be had--I think a question in OS2CM CFORUM
  6879. will flush them out.  The official documentation of CPIC in general as
  6880. well as the REXX info is in the SAA CPI-C reference, SC26-4399.
  6881.  
  6882. Steve Price        SAA REXX Development
  6883.  
  6884. ----- OS2REXX CFORUM appended at 05:29:15 on 92/09/29 GMT (by IL78711 at OS2CUST)
  6885. Subject: VREXX and OOREXX
  6886. Ref: Append at 18:39:28 on 92/09/27 GMT (by PRICESG at GDLVM7)
  6887.  
  6888. I like what I see in Visual Rexx. However I am cautious about using it for
  6889. any significant development. Why is it unsupported?? I would like it to be
  6890. included in the OS/2 base. This implementation looks like it required quite
  6891. a bit of hardwork and computer skill. Is there something about it that we
  6892. should know? in other words why is it not supported. It clearly meets a very
  6893. strategic requirement.
  6894.  
  6895. Marvin Lichtenthal
  6896.  
  6897. ----- OS2REXX CFORUM appended at 13:52:07 on 92/09/29 GMT (by IL48722 at OS2CUST)
  6898. Subject: CPI-C functions for REXX
  6899. Ref: Append at 20:59:45 on 92/09/28 GMT (by PRICESG at GDLVM7)
  6900.  
  6901. Such a deal, indeed!
  6902.  
  6903. Funny thing, though -- NONE of the documentation I got with ES 1.0
  6904. mentions that CPI-C calls are available from REXX!  In fact, the
  6905. Sales Manual entry for Extended Services says:
  6906.  
  6907. * APPC is support[sic] by C (including IBM C SET/2), COBOL and Macro
  6908. Assembler
  6909.  
  6910. I'll ask over on the OS2CM CFORUM for further information.
  6911.  
  6912. Thanks!
  6913.  
  6914. Bob Beilstein, Manugistics, Inc.  (315) 458-0723
  6915.  
  6916. ----- OS2REXX CFORUM appended at 12:50:11 on 92/09/30 GMT (by RBLAM at YKTVMV)
  6917. Subject: VREXX and OOREXX
  6918. Ref:     Append at 05:29:15 on 92/09/29 GMT (by IL78711 at OS2CUST)
  6919.  
  6920. I was a bit surprised that so many users in IBM liked VREXX when I
  6921. posted it to the internal tools disk.  VREXX was originally written
  6922. only as a demonstration program for some other internal tools.  I
  6923. received a lot of feedback on improving the package and I implemented
  6924. quite a few user suggestions.  The present version offers quite a
  6925. bit of functionality with very easy-to-use function calls.
  6926.  
  6927. Although several marketing people approached me about making VREXX
  6928. available, there was never any formal product plan.  VREXX WAS
  6929. used to write some installation tools for a number of custom software
  6930. contracts with external customers.
  6931.  
  6932. Given the high level of use internally, I thought a large number of
  6933. external customers could also benefit if it were released.
  6934. I felt the best way to get VREXX out to customers was to release it
  6935. through the EWS program.  It's free and available immediately, although
  6936. without support (all EWS programs are offered without support).
  6937.  
  6938. I don't know of any plans to include VREXX with future releases of
  6939. OS/2, but you could lobby your marketing representative to have it
  6940. included.  A large base of users is a strong argument...
  6941.  
  6942. I hope this at least partly answers your question, and I also hope
  6943. you find VREXX useful.  Thanks!
  6944.  
  6945. - Dick Lam
  6946.  
  6947. ----- OS2REXX CFORUM appended at 14:13:34 on 92/09/30 GMT (by XXMUTL27 at TORVMCOP)
  6948. Subject: Starting objects serially
  6949. Ref:     Append at 19:37:18 on 92/09/28 GMT (by AYP1Q01 at OS2CUST)
  6950.  
  6951. I also have a second reason for wanting to serialize a program started
  6952. with SysCreateObject. This is easiest to explain with an example.
  6953.  
  6954. I have an OS/2 Window object available on my desktop. Opening it starts
  6955. CMD.EXE. If I subsequently "open" the same OS/2 Window object the
  6956. original one is placed in the foreground. Typing "e" (NOT "start e")
  6957. starts the System Editor. Displaying the task list would show that
  6958. "OS/2 Window" has been replaced by "E.EXE". Also, double-clicking on
  6959. the OS/2 Window object now brings the System Editor to the foreground.
  6960.  
  6961. If a call to SysCreateObject could be serialized, then I would expect
  6962. the same behaviour. However, if a solution to the net use problem were
  6963. to preclude this, I could live with that.
  6964.  
  6965. I also thought of checking running tasks to see if the program started
  6966. was still running. If not then do the "net use d: /d". However, I'd
  6967. prefer a "cleaner" solution.
  6968.  
  6969. Erik Vander Ahe
  6970. The Mutual Group
  6971.  
  6972. ----- OS2REXX CFORUM appended at 19:22:15 on 92/09/30 GMT (by SBSTBEG at OS2CUST)
  6973. Subject: VREXX and OOREXX
  6974. Ref: Append at 12:50:11 on 92/09/30 GMT (by RBLAM at YKTVMV)
  6975.  
  6976. Dick,
  6977.     I like the VREXX alot, have shown it to a couple of guy's here, and you
  6978. might think I was showing them mana from heaven.  It's great for those quick
  6979. and dirty programs.  After only two days, I have converted several of my
  6980. command line interface programs to use VREXX.  I would like to see it ofically
  6981. supported, and included in future releases.  Unless I'm missing something, it
  6982. would be nice to have an option to size some of the windows, such as the
  6983. various input, and selection boxes.  Keep up the excellent work!!!
  6984.  
  6985. Bill Stephens
  6986.  
  6987. ----- OS2REXX CFORUM appended at 20:56:38 on 92/09/30 GMT (by BONILLA at KGNVMZ)
  6988. Subject: VREXX and OOREXX
  6989. Ref:     Append at 05:29:15 on 92/09/29 GMT (by IL78711 at OS2CUST)
  6990.  
  6991. Marvin, as the author has indicated in his append, VREXX is not
  6992. a product. It is one of a number of programs or mini-applications
  6993. that were developed by some of our employees for their own use or
  6994. for other employees to use. The OS2EWS program is an attempt to
  6995. release these programs for the use of OS/2 customers who might
  6996. find them useful. They are released with an AS-IS warranty, are
  6997. offered at no charge to the customer and are not supported by the
  6998. company. If you find them useful, we are happy. While they have
  6999. been used extensively in general, within IBM, they have not been
  7000. subjected to the rigorous testing that products face. Our hope
  7001. is that some customers will find them useful.
  7002.  
  7003. John Bonilla
  7004.  
  7005. ----- OS2REXX CFORUM appended at 06:07:33 on 92/10/01 GMT (by IL78711 at OS2CUST)
  7006. Subject: VREXX and OOREXX
  7007. Ref: Append at 20:56:38 on 92/09/30 GMT (by BONILLA at KGNVMZ)
  7008.  
  7009. Vrexx2 is too good not to be used by IBM customers. It gives OS/2 a very
  7010. significant competitive advantage. Without being a product some customers
  7011. will hesitate to use it.
  7012.  
  7013. ----- OS2REXX CFORUM appended at 14:18:03 on 92/10/01 GMT (by CONT00 at LEXVMK)
  7014. Subject: VREXX and OOREXX
  7015. Ref:     Append at 06:07:33 on 92/10/01 GMT (by IL78711 at OS2CUST)
  7016.  
  7017. If you are looking for supported, nice, quite powerful, easy to use
  7018. PM interface - without the need to program yourself the PM/C stuff, look
  7019. for PL1 for OS/2. Wouldn't it be nice if REXX had a similar one, in
  7020. supported manner ?
  7021. (PL1OS/2 is great, if only the price were lower...)
  7022.  
  7023. Gregory Czaja, Lexington 8-545-3311  1992/10/01  10:14
  7024.  
  7025. ----- OS2REXX CFORUM appended at 19:44:25 on 92/10/01 GMT (by V$IGREGO at BCRVM7)
  7026. Subject: Maximum size LINEIN can read
  7027.  
  7028. Does anyone know what the maximum size in bytes LINEIN can read ???
  7029. Chris
  7030.  
  7031. ----- OS2REXX CFORUM appended at 20:20:43 on 92/10/01 GMT (by MCBRIDEC at WMAVM7)
  7032. Subject: SysFileTree utility question
  7033.  
  7034. (warning: somewhat long append...)
  7035.  
  7036. I did not find any other appends about this topic so here is my
  7037. question.  When I use the SysFileTree function in a Rexx program
  7038. with the following syntax, I do not get the expected results:
  7039.  
  7040. call SysFileTree 'C:\*.*', 'file', 'FO', '+****', '-****'
  7041.  
  7042. The online documentation says that the second set of attribute
  7043. characters should turn off the A (archive) flag.  Everything
  7044. else about the command seems to work correctly -- the "file"
  7045. stem has a list of all files in the root directory that have
  7046. the archive flag set.  However, as I understand it, this command
  7047. should also reset the archive flag to off because of the "-" in
  7048. the archive field of the last argument (I cannot remember what
  7049. the documentation named the arguments).  Am I doing something
  7050. wrong?  If I run the ATTRIB C:\*.* command before and after
  7051. executing my program all of the files attribute remain unchanged.
  7052.  
  7053. I reduced the .cmd file to the following, but still no luck.
  7054.  
  7055. /*-----------------------------------------------------------------*/
  7056. /* Load the Rexx Utility functions                                 */
  7057. /*-----------------------------------------------------------------*/
  7058. call RxFuncAdd 'SysLoadFuncs', 'RexxUtil', 'SysLoadFuncs'
  7059. call SysLoadFuncs
  7060.  
  7061. /*-----------------------------------------------------------------*/
  7062. /* Find all file in C:\ that have archive flag set and clear it.   */
  7063. /*-----------------------------------------------------------------*/
  7064. call SysFileTree 'C:\*.*', 'file', 'FO', '+****', '-****'
  7065.  
  7066. do i = 1 to file.0
  7067.   say i':' file.0
  7068. end
  7069.  
  7070. exit
  7071.  
  7072. The program will indeed print out all files in C:\ that have
  7073. the archive flag set.  But the flag will remain unchanged after
  7074. execution.
  7075.  
  7076. Sorry for the long append.
  7077.  
  7078. Cliff McBride - Gaithersburg, MD
  7079.  
  7080. ----- OS2REXX CFORUM appended at 21:48:36 on 92/10/01 GMT (by IL32772 at OS2CUST)
  7081. Subject: Com Mgr control
  7082. Ref: Append at 22:41:24 on 92/09/21 GMT (by NAAO3IY at OS2CUST)
  7083.  
  7084. Thanks for the reply, I have used visited the hllapi doc before.  What I
  7085.  did not make clear was manage: can I use a REXX interface to start a 3270/5250
  7086. session that is not active, or fails for some reason and I need to stop and res
  7087. tart the session.  The Hllapi only handles active sessions, not inactive sessio
  7088. n starting.  Hopefully this make more sense.
  7089.  
  7090. Randy Cairns
  7091.  
  7092. ----- OS2REXX CFORUM appended at 00:30:43 on 92/10/02 GMT (by IL19543 at OS2CUST)
  7093. Subject: Does VREXX trap out on your XGA?
  7094.  
  7095. I have tried VREXX samples on several machines.  VGA PS/2's work just great,
  7096. but on a XGA machine we get a SYS3175 error on exit from the sample.
  7097. Does this happen on your XGA or is it isolated to this one particular machine?
  7098.  
  7099. This VREXX looks very nice, I will have to spend the time to learn all of
  7100. REXX to make full use of this tool.
  7101. Thanks,
  7102.  
  7103. Mike Long - CARD Iowa State University - PC/LAN Analyst
  7104.  
  7105. ----- OS2REXX CFORUM appended at 12:56:12 on 92/10/02 GMT (by XXMUTL27 at TORVMCOP)
  7106. Subject: SysFileTree utility question
  7107. Ref:     Append at 20:20:43 on 92/10/01 GMT (by MCBRIDEC at WMAVM7)
  7108.  
  7109. I've had the same problem, but trying to clear the read-only bit. My
  7110. workaround was to use attrib, but you do notice a performance lag while
  7111. OS/2 loads attrib.
  7112.  
  7113. Erik Vander Ahe
  7114. The Mutual Group
  7115.  
  7116. ----- OS2REXX CFORUM appended at 13:03:42 on 92/10/02 GMT (by XXMUTL27 at TORVMCOP)
  7117. Subject: Does VREXX trap out on your XGA?
  7118. Ref:     Append at 00:30:43 on 92/10/02 GMT (by IL19543 at OS2CUST)
  7119.  
  7120. I too have had VREXX generate a SYS3175. It is reproducable. If my REXX
  7121. program has a syntax error, ending the program, then subsequent
  7122. executions of any other REXX program that attempts to use VREXX will
  7123. trap out. Although my machine is not hung, OS/2 will not shutdown. An
  7124. IPL does fix the problem. For example:
  7125.  
  7126. call RxFuncAdd SysLoadFuncs,RexxUtil,SysLoadFuncs
  7127. call SysLoadFuncs
  7128. call RxFuncAdd HLLAPI,SAAHLAPI,HLLAPISRV
  7129. call RxFuncAdd VInit,VREXX,Vinit
  7130. rc = VInit()
  7131. if rc = 'ERROR' then signal CleanUp
  7132. signal on error name CleanUp
  7133. signal on failure name CleanUp
  7134. signal on halt name CleanUp
  7135. signal on syntax name CleanUp
  7136.  
  7137. say 'I forgot a quote at the end of this line.
  7138.  
  7139. CleanUp:
  7140.     call HLLAPI 'Disconnect'
  7141.     call VExit
  7142.     exit
  7143.  
  7144. Erik Vander Ahe
  7145. The Mutual Group
  7146.  
  7147. ----- OS2REXX CFORUM appended at 13:41:25 on 92/10/02 GMT (by XXSHLW02 at TORVMCOP)
  7148. Subject: VREXX and OOREXX (& PL/1)
  7149. Ref:     Append at 14:18:03 on 92/10/01 GMT (by CONT00 at LEXVMK)
  7150.  
  7151. I have been awaiting PL/1 for OS/2, and have not seen an announcement..
  7152. Are you referring to a non-IBM product, or is this not yet
  7153. available in Canada?
  7154.  
  7155. Bruce Popham (SHL Systemhouse - Wpg)
  7156.  
  7157. ----- OS2REXX CFORUM appended at 14:26:06 on 92/10/02 GMT (by TCC3824 at OS2CUST)
  7158. Subject: Does VREXX trap out on your XGA?
  7159. Ref: Append at 13:03:42 on 92/10/02 GMT (by XXMUTL27 at TORVMCOP)
  7160.  
  7161. I have the same problem!  Running p75 with 8514 & XGA.
  7162.  
  7163. VREXX IS GREAT!!  I HAVE SHOWN IT TO 20+ DEVELOPERS IN MY SHOP AND THERE
  7164. IS MUCHO INTEREST!!  HOPE TO SEE THIS AS A SUPPORTED PRODUCT.
  7165. IT TOOK ME ABOUT AN HOUR TO CONVERT 5 TEXT BASED REXX MENUS TO DIALOGS THAT
  7166. I AM NOW USING FOR ONE OF MY TOOLS.
  7167.  
  7168. Kevin McConnell   512-338-7457  Continuum    Austin Tx
  7169.  
  7170. ----- OS2REXX CFORUM appended at 16:41:03 on 92/10/02 GMT (by CONT00 at LEXVMK)
  7171. Subject: VREXX and OOREXX (& PL/1)
  7172. Ref:     Append at 13:41:25 on 92/10/02 GMT (by XXSHLW02 at TORVMCOP)
  7173.  
  7174. Sorry, don't know the ivory number...
  7175.  
  7176. Today, IBM announces SAA PL/I Package/2, a 32-bit IBM developed
  7177. implementation of PL/I on OS/2 2.0. It will GA (in the USA) Sept 25.
  7178. It implements:
  7179.  
  7180.   * The SAA PL/I CPI (SC23-4381)
  7181.       + plus a few additional features from S/370 OS PL/I Version 2
  7182.         Release 3 (e.g. FETCH, the macro facility)
  7183.       - minus a few items
  7184.   * A truck-load of new function, addressing hundreds of user
  7185.     requirements permitting exploitation of OS/2 including the
  7186.     Presentation Manager.
  7187.   * VSAM-like record level I/O for indexed, relative and
  7188.     consecutive data sets in addition to STREAM I/O and printer
  7189.     destined (host or local) files
  7190.   * Syntax and semantic checking of OS PL/I V2R3 language (e.g.
  7191.     multitasking language) that is yet not part of SAA PL/I.
  7192.   * Selected features of ANS 87 PL/I
  7193.  
  7194. Minimum recommended configuration:
  7195.  
  7196.   * PS/2 386SX or better (or compatible) + Math coprocessor
  7197.   * 8MB RAM
  7198.   * 10MB free disk space
  7199.  
  7200. Publications:
  7201.  
  7202.   PL/I Package/2 Fact Sheet                             GC26-3090
  7203.   PL/I Package/2 Licensed Program Specifications        GC26-4821
  7204.   PL/I Package/2 Installation                           SX26-3822
  7205.  
  7206.   PL/I Package/2 Programming Guide                      SC26-4822
  7207.   PL/I Package/2 Language Reference                     SC26-4823
  7208.   PL/I Package/2 Reference Summary                      SX26-3793
  7209.   PL/I Package/2 Language Environment Run-Time Messages SC26-3133
  7210.   (Package of above 4 books)                            SBOF-3014
  7211.  
  7212.  Please pass the great news to your friends and colleagues.
  7213.  
  7214. Gregory Czaja, Lexington 8-545-3311  1992/10/02  12:37
  7215.  
  7216. ----- OS2REXX CFORUM appended at 13:44:47 on 92/10/05 GMT (by PERSHNG at YKTVMH)
  7217. Subject: VREXX and OOREXX (& PL/1)
  7218. Ref:     Append at 16:41:03 on 92/10/02 GMT (by CONT00 at LEXVMK)
  7219.  
  7220. The ivory letter number is 292-501.
  7221.  
  7222. One "feature" that Gregory omitted is the price tag: $2750.
  7223.  
  7224. John A. Pershing Jr.
  7225.  
  7226. ----- OS2REXX CFORUM appended at 17:18:15 on 92/10/05 GMT (by NAAO3IY at HONE82)
  7227. ..... OS2REXX CFORUM modified at 03:36:40 on 92/10/06 GMT (by HOPKINS at AUSVM8)
  7228. Subject: oops, try again, no text in append -ken
  7229. Ref: Append at 21:48:36 on 92/10/01 GMT (by IL32772 at OS2CUST)
  7230.  
  7231. ----- OS2REXX CFORUM appended at 17:44:25 on 92/10/05 GMT (by PETERHS at DKIBMVM2)
  7232. Subject: How to create WPPRINT class-object using REXXUTIL (SysCreate..)
  7233.  
  7234. I would like to create a Printer Object (class=WPPRINT) using the
  7235. SysCreateObject call from REXX. But I can't find documentation on
  7236. the attribut SETUP, which is the key to make a LAN Printer
  7237. object.
  7238.  
  7239. Please Help. Peter Holm, Denmark.
  7240.  
  7241. ----- OS2REXX CFORUM appended at 19:12:56 on 92/10/05 GMT (by NAAO3IY at OS2CUST)
  7242. Subject: Com Mgr control
  7243. Ref: Append at 21:48:36 on 92/10/01 GMT (by IL32772 at OS2CUST)
  7244.  
  7245. "Inactive session" is a bit ambiguous.  You can use HLLAPI to log on
  7246. (at least to 3270 -- I don't know the 5250 world), but you can't use
  7247. it to go to Communications Manager and issue a start.  However, you
  7248. could use REXX to start Communications Manager itself, and you should
  7249. be able to arrange matters so that that would cover 99.9% of cases.
  7250.  
  7251. John Kennedy -- Hoechst Celanese, Bridgewater, NJ (The OS/2 Hobbit)
  7252.  
  7253. ----- OS2REXX CFORUM appended at 13:56:32 on 92/10/06 GMT (by HITTR at OS2CUST)
  7254. Subject: syscreateobject and linefeed problem
  7255.  
  7256. The syscreateobject is not taking the linefeed in the setup='set dos_version li
  7257. ne.  I have tried two ways to do this, one by assigning a variable to '0A'x and
  7258.  then putting the variable in the line.  The other method is putting an alt num
  7259. eric keypad 10.  The variables are set (classname, location, setup, title)
  7260. and a procedure is called with the syscreateobject.  I am getting the setup
  7261. from an object that was created just prior to the one with the line feed.
  7262.  
  7263. If I make the cmd file to only build the one object, it still gets the setup
  7264. from the the previous object created successfully.  If it is run on a machine a
  7265. fter a fresh bootup, the SETUP is not taken at all.  The setup items in the ico
  7266. n are all blank/default.
  7267.  
  7268. By the way, the goal is to create Lotus 123 3.1+ icon with the lotus exes and c
  7269. oms in the dos_version section of the dos settings.  Any help would be greatly
  7270. appreciated.
  7271.  
  7272. Bob Hitt, Missouri Highway & Transportation Department
  7273.  
  7274. ----- OS2REXX CFORUM appended at 15:09:00 on 92/10/06 GMT (by PERSHNG at YKTVMH)
  7275. Subject: VREXX and OOREXX (& PL/1)
  7276. Ref:     Append at 13:44:47 on 92/10/05 GMT (by PERSHNG at YKTVMH)
  7277.  
  7278. I got a copy of PL/I-for-OS/2 (PL/I/2 ?), and it looks like it is a
  7279. really super implementation.  The best thing is that the compiler
  7280. actually admits that its programs will operate in an "environment" that
  7281. is defined by the operating system (OS/2 with PM) rather than by PL/I;
  7282. so, it appears to be absolutely straightforward to interface with the
  7283. system facilities.  (Now, if only the PL/I-for-CMS compiler would admit
  7284. that it is operating in a CMS environment... :-)
  7285.  
  7286. Indeed, there's a "truck-load of new function".
  7287.  
  7288. John A. Pershing Jr.
  7289.  
  7290. ----- OS2REXX CFORUM appended at 15:18:30 on 92/10/06 GMT (by JERKEWIT at DALVM41B)
  7291. Subject: SysFileTree not finding $file
  7292. Greetings,  I have come upon a peculiar result in using
  7293. SysFileTree.  I have a directory with 15 files, 7 of which
  7294. start with a $. If I issue SysFileTree "C:\mydir\*" stem
  7295. I do not retrieve the files that start with a $. However,
  7296. when I issue  SysFileTree "C:\mydir\$*" stem I do get the
  7297. $ files. I wish to retrieve ALL files, How do I do this?
  7298. or is this an insect of sorts?
  7299.  
  7300. thanx for any help
  7301. Peter Jerkewitz @ DALVM41B
  7302.  
  7303. ----- OS2REXX CFORUM appended at 15:31:38 on 92/10/06 GMT (by ALIU at BOSTON) -
  7304. Subject: Thanks - Trying to get file info
  7305.  
  7306. I just wanted to write a note of thanks to all those helpful folks
  7307. who took the time to send me notes on obtaining directory information
  7308. on PC files. The sample program fragments and programming advice was
  7309. very helpful indeed. For those interested, I finally settled on using
  7310. the QUERYINFO function. It may also interest you to know the customer
  7311. was very impressed with the capabilities of the REXX/2 language, and
  7312. is trying to learn REXX himself (He's only had prior experience with
  7313. mainframes.) on the PC! Thanks again!
  7314.  
  7315. Art Liu (ALIU @ BOSTON)
  7316. IBM Services Company
  7317. Client Server Practice
  7318.  
  7319. ----- OS2REXX CFORUM appended at 17:20:04 on 92/10/06 GMT (by MCGUIRE at GDLVM7)
  7320. Subject: SysFileTree not finding $file
  7321. Ref:     Append at 15:18:30 on 92/10/06 GMT (by JERKEWIT at DALVM41B)
  7322.  
  7323. I'm unable to reproduce this problem on either FAT or HPFS, so I'm not sure
  7324. what to tell you.  You might want to try using the filespec 'C:\mydir\*.*'
  7325. instead.
  7326.  
  7327. Rick McGuire - SAA Rexx Development, Endicott
  7328.  
  7329. ----- OS2REXX CFORUM appended at 18:19:04 on 92/10/06 GMT (by JERKEWIT at DALVM41B)
  7330. Subject:SysFileTree not finding $
  7331. If I issue SysFileTree "\\PLUTO\RSC\mydir\*" stem
  7332. I get all the files, including $TEST.Fil.
  7333. When I issue the same thing to a local HPFS drive
  7334. I do not get the $ files. Am running GA OS/2 2.0.
  7335.  
  7336. If I issue SysFileTree "C:\mydir\?T*" stem
  7337. I get the expected results.
  7338.  
  7339. thanx for any help Rick
  7340. Peter Jerkewitz @ DALVM41B
  7341.  
  7342. ----- OS2REXX CFORUM appended at 19:09:37 on 92/10/06 GMT (by CONT00 at LEXVMK)
  7343. Subject: syscreateobject and linefeed problem
  7344. Ref:     Append at 13:56:32 on 92/10/06 GMT (by HITTR at OS2CUST)
  7345.  
  7346. The following code illustrates what you should do:
  7347.   setup=,
  7348.   'SET DOS_VERSION=EXE2BIN.COM^,5^,0^,255'||'0A'X||xxxxx^,5^,0^,255;'||,
  7349.   'SET DOS_DEVICE=C:\OS2\MDOS\ANSI.SYS'||','||'C:\OS2\MDOS\EGA.SYS';
  7350. It translates to:
  7351. - to separate multivalue entries for the same SET_DOS... use either
  7352.   '0A'x or ','(which gets translated to newline),
  7353. - to separate values for an entry (separator appears externally as ","
  7354.   on the settings page), use "^,". The carat "^"(shift-6) is used as an
  7355.   escape character switching off the translation of ",".
  7356.   (BTW: you have to use "^" for semicolons if used as a value in a setup
  7357.    string).
  7358.  
  7359. Since you don't mention the 5-th parameter of SysCreateObject, I assume
  7360. that you don't have the current REXXUTIL.DLL - look for REXX20 update.
  7361. The problem with setup string being taken over from the last valid object
  7362. create was fixed by SOMFIX some time ago (May ?).
  7363. Also look for an append in this forum by MIKELAMB at KGNVMC dated
  7364. 92/06/19 at 12:37:10.
  7365.  
  7366. Gregory Czaja, Lexington 8-545-3311  1992/10/06  14:56
  7367.  
  7368. ----- OS2REXX CFORUM appended at 19:46:35 on 92/10/06 GMT (by MCGUIRE at GDLVM7)
  7369. Subject: SysFileTree not finding $
  7370. Ref:     Append at 18:19:04 on 92/10/06 GMT (by JERKEWIT at DALVM41B)
  7371.  
  7372. Ok, got it working (or failing actually...I could have sworn that that disk
  7373. was formatted HPFS the first time!).  I traced through the Rexx code, and it
  7374. looks like these files aren't even being returned by the DosFindNext code.
  7375. This looks like a file system problem.
  7376.  
  7377. Rick McGuire - SAA Rexx Development, Endicott
  7378.  
  7379. ----- OS2REXX CFORUM appended at 00:20:32 on 92/10/07 GMT (by BCHI040 at OS2CUST)
  7380. Subject: VREXX2 Problems, Access violation VREXX.DLL
  7381.  
  7382. I just downloaded a very nice PM interface for REXX lots of
  7383. functionality but I have one problem I can only run my rex
  7384. application only one time. Any time after teh first execution I
  7385. receive a Program generated an access violation at 16f101fc VREXX.DLL
  7386. 0001.
  7387.  
  7388. I hope there is a solution to this because I really like the idea of
  7389. a PM interface for REXX.
  7390.  
  7391. Jerry Hittle, Hawaii Medical Service Ass'n  P.O. Box 860 Hon Hi 96808
  7392.  
  7393. ----- OS2REXX CFORUM appended at 02:53:58 on 92/10/07 GMT (by IL41468 at HONE81)
  7394. Subject: VREXX2 Problems, Access violation VREXX.DLL
  7395. Ref: Append at 00:20:32 on 92/10/07 GMT (by BCHI040 at OS2CUST)
  7396.  
  7397. Jerry:
  7398. Did you call VExit at the end of your routine? If you don't Vrexx is locked
  7399. to you until you boot again.
  7400.  
  7401.  J.M.Schaeffer ('John' AIMS Sandy, Utah)
  7402.  
  7403. ----- OS2REXX CFORUM appended at 11:08:38 on 92/10/07 GMT (by SSYYED at GNKVM2)
  7404. Subject: SYSCREATEOBJECT SYSSETOBJECTDATA
  7405.  
  7406. I cannot create an object correctly when using a SETUP string
  7407. greater than 256 Characters. Either the object is not created
  7408. with the right program, or with default DOS SETTINGS,,
  7409.  
  7410. While SETOBJECTDATA resets all DOS SETTINGS and only uses
  7411. what is passed (as opposed to modifying),
  7412.  
  7413. Are these working properly ?? Is there a way around these ?
  7414.  
  7415. Thanks
  7416. Sohail Syyed
  7417.  
  7418. ----- OS2REXX CFORUM appended at 14:14:07 on 92/10/07 GMT (by CONT00 at LEXVMK)
  7419. Subject: SYSCREATEOBJECT SYSSETOBJECTDATA
  7420. Ref:     Append at 11:08:38 on 92/10/07 GMT (by SSYYED at GNKVM2)
  7421.  
  7422. The new version of PMWIN (available in 32bit GRE: in beta now and in
  7423. Service PAck) lifts the limit on the 256 character setup string.
  7424.  
  7425. Gregory Czaja, Lexington 8-545-3311  1992/10/07  10:12
  7426.  
  7427. ----- OS2REXX CFORUM appended at 17:17:35 on 92/10/07 GMT (by BCHI040 at OS2CUST)
  7428. Subject: VREXX2 Problems, Access violation VREXX.DLL
  7429. Ref: Append at 02:53:58 on 92/10/07 GMT (by IL41468 at HONE81)
  7430.  
  7431. Here is the test.cmd file that I am having problems with, still locks up....
  7432.        '@echo off'
  7433.        call RxFuncAdd 'VInit', 'VREXX', 'VINIT'
  7434.        initcode = VInit()
  7435.        if initcode = 'ERROR' then signal CLEANUP
  7436.  
  7437.        signal on failure name CLEANUP
  7438.        signal on halt name CLEANUP
  7439.        signal on syntax name CLEANUP
  7440.  
  7441.        item.0 = 9
  7442.        item.1 = 'D:\dbiw\ddl\TBGRP.DDL'
  7443.        item.2 = 'D:\dbiw\ddl\TBGBNFT.DDL'
  7444.        item.3 = 'D:\dbiw\ddl\TBBSUMM.DDL'
  7445.        item.4 = 'D:\dbiw\ddl\TBIWMBR.DDL'
  7446.        item.5 = 'D:\dbiw\ddl\TBSBNFT.DDL'
  7447.        item.6 = 'D:\dbiw\ddl\TBSFIN.DDL'
  7448.        item.7 = 'D:\dbiw\ddl\TBSUBS.DDL'
  7449.        item.8 = 'D:\dbiw\ddl\TBPRV.DDL'
  7450.  
  7451.          item.9 = 'D:\dbiw\ddl\TBOPER.DDL'
  7452.  
  7453.          call VCheckBox 'Select Item(s)', item, selection, 1
  7454.  
  7455.          do i = 1 to selection.0
  7456.           say(selection.i)
  7457.          end
  7458.          call VMsgBox 'Selected item(s)', selection, 1
  7459.  
  7460.          call VExit
  7461.  
  7462.          CLEANUP:
  7463.             call VExit
  7464.          exit
  7465.  
  7466.  If you have any suggestions let me know.  Thanks...
  7467.  
  7468. Jerry Hittle, Hawaii Medical Service Ass'n  P.O. Box 860 Hon Hi 96808
  7469.  
  7470. ----- OS2REXX CFORUM appended at 17:41:12 on 92/10/07 GMT (by XXSEAR12 at TORVMCOP)
  7471. Subject: Starting objects serially
  7472. Ref:     Append at 19:12:31 on 92/09/25 GMT (by XXMUTL27 at TORVMCOP)
  7473.  
  7474. Here's another vote for a solution.
  7475.  
  7476. We need to be able to run DOS applications especially 123 in the LAN environment
  7477. Can anyone help ?
  7478.  
  7479. Matt Armata, Sears Canada Inc.
  7480.  
  7481. .
  7482.  
  7483. ----- OS2REXX CFORUM appended at 18:58:22 on 92/10/07 GMT (by BCHI040 at OS2CUST)
  7484. Subject: Does VREXX trap out on your XGA?
  7485. Ref: Append at 13:03:42 on 92/10/02 GMT (by XXMUTL27 at TORVMCOP)
  7486.  
  7487. I to have had some problems with SYS3175 errors. If I run the demo progrms they
  7488.  work fine but when I create a small test.cmd to try one function and I do incl
  7489. ude the call VExit I crash upon exit with a SYS3175.  Once the error is issued
  7490. I can no longer shutdown I have to CTRL-ALT-DEL to IPL the system.
  7491.  
  7492. Here is my test.cmd code
  7493.  
  7494. /* TEST.CMD */
  7495. '@echo off'
  7496. call RxFuncAdd 'VInit', 'VREXX', 'VINIT'
  7497. initcode = VInit()
  7498. if initcode = 'ERROR' then signal CLEANUP
  7499. signal on failure name CLEANUP
  7500. signal on halt name CLEANUP
  7501. signal on syntax name CLEANUP
  7502. Signal on error name CLEANUP
  7503. item.0 = 9
  7504. item.1 = 'D:\dbiw\ddl\TBGRP.DDL'
  7505. item.2 = 'D:\dbiw\ddl\TBGBNFT.DDL'
  7506. item.3 = 'D:\dbiw\ddl\TBBSUMM.DDL'
  7507. item.4 = 'D:\dbiw\ddl\TBIWMBR.DDL'
  7508. item.5 = 'D:\dbiw\ddl\TBSBNFT.DDL'
  7509. item.6 = 'D:\dbiw\ddl\TBSFIN.DDL'
  7510. item.7 = 'D:\dbiw\ddl\TBSUBS.DDL'
  7511. item.8 = 'D:\dbiw\ddl\TBPRV.DDL'
  7512. item.9 = 'D:\dbiw\ddl\TBOPER.DDL'
  7513. call VCheckBox 'Select Item(s)', item, selection, 1
  7514. do i = 1 to selection.0
  7515.  say(selection.i)
  7516. end
  7517. call VMsgBox 'Selected item(s)', selection, 1
  7518. CLEANUP:
  7519.  call VExit
  7520.  Exit
  7521.  
  7522. I really like this tool and hope to find a solution.  I also hope IBM realizes
  7523. the potential of this tool and makes it part of the production OS/2.
  7524.  
  7525. Thanks
  7526.  
  7527. Jerry Hittle, Hawaii Medical Service Ass'n  P.O. Box 860 Hon Hi 96808
  7528.  
  7529. ----- OS2REXX CFORUM appended at 19:43:03 on 92/10/07 GMT (by MUELLER at AUSVM6)
  7530. Subject: SYSCREATEOBJECT SYSSETOBJECTDATA
  7531. Ref:     Append at 14:14:07 on 92/10/07 GMT (by CONT00 at LEXVMK)
  7532.  
  7533. Is there a way to set the Desktop - Settings Background Display mode
  7534. (Normal, Tiled or Scaled,) under the 32bGRE?
  7535.  
  7536. On GA the default is always Scaled.
  7537.  
  7538. J e r r y    MUELLER@AUSVM6.VNET.IBM.COM
  7539.  
  7540. ----- OS2REXX CFORUM appended at 00:10:44 on 92/10/08 GMT (by IL41468 at HONE84)
  7541. Subject: VREXX2 Problems, Access violation VREXX.DLL
  7542. Ref: Append at 17:17:35 on 92/10/07 GMT (by BCHI040 at OS2CUST)
  7543.  
  7544. Jerry:
  7545. In the code you are executing VExit twice. Try it pulling out the first call
  7546. VExit. Rexx drops through a label. I don't know if this will work but try it
  7547. and see.
  7548.  
  7549. J.M.Schaeffer ('John' AIMS Sandy, Utah)
  7550.  
  7551. ----- OS2REXX CFORUM appended at 00:11:35 on 92/10/08 GMT (by IL41468 at HONE84)
  7552. Subject: Does VREXX trap out on your XGA?
  7553. Ref: Append at 18:58:22 on 92/10/07 GMT (by BCHI040 at OS2CUST)
  7554.  
  7555. Jerry:
  7556. How far to you get in the REXX procedure. Does the say selection.i work?
  7557. do you get the VMsgBox window?
  7558.  
  7559. J.M.Schaeffer ('John' AIMS Sandy, Utah)
  7560.  
  7561. ----- OS2REXX CFORUM appended at 17:42:10 on 92/10/08 GMT (by NAAG8T6 at OS2CUST)
  7562. Subject: Does VREXX trap out on your XGA?
  7563. Ref: Append at 18:58:22 on 92/10/07 GMT (by BCHI040 at OS2CUST)
  7564.  
  7565. I have the same problem - SYS3175 trying to test a VREXX procedure. I am
  7566. also using XGA. I was testing VMultBox. Sometimes the box appears but more
  7567. often the session crashes with SYS3175 and then I haven't found how to
  7568. recover without reboot (and then it mostly happens again...). I run the
  7569. VExit code if it gets there (the SYS3175 screen makes it hard to tell if
  7570. it really ran or not).
  7571.  
  7572. I also would like to vote for IBM extending this freeware into a product
  7573. along the lines of Visual Basic.
  7574.  
  7575. Bruce Ferrero @ Aetna, Middletown, CT
  7576.  
  7577. ----- OS2REXX CFORUM appended at 20:10:26 on 92/10/08 GMT (by ALIU at BOSTON) -
  7578. ..... OS2REXX CFORUM modified at 21:12:02 on 92/10/08 GMT (by ALIU at BOSTON) .
  7579. Subject: Can I use PC Support APIs in REXX program?
  7580. *** Fixed Typos - Ughhh!!! ***
  7581. *** Fixed Wrong Manual Number ***
  7582. ======================================================================
  7583. The following was originally posted in PC CFORUM under IBMS3X Forum.
  7584. I'm hoping someone can help out here as well.
  7585. ======================================================================
  7586. Hi!
  7587.  
  7588. We've got a question relating to using PC Support APIs in a REXX
  7589. program on a PS/2 running OS/2 V2.0 and AS/400 PC Support.
  7590.  
  7591. Our team is performing services contract work for a customer, and
  7592. one of our to do's is to write a REXX program to
  7593. automate upload of an ASCII file (containing sales order data) on
  7594. a PS/2 to a data queue on their AS/400, performing ASCII to EBCDIC
  7595. conversion in the process.
  7596.  
  7597. Specifically, we're looking at using the QSNDDTAQ API to accomplish
  7598. the sending of the file to the data queue, but I suppose my question
  7599. can be generalized to using PC Support APIs in languages other than
  7600. REXX and PASCAL. (See p. 14-29 of the PC Support API Reference manual,
  7601. | SC41-8254.) As a last bit of confusion / difficulty, QSNDDTAQ seems to
  7602. expect a Field Name for data to send, while I have a PC File to send to
  7603. | the queue.
  7604.  
  7605. The AS/400 PC Support API Reference Manual states that
  7606. | these APIs can be used "in any programming language" that runs on
  7607. the PS/2. The examples in the manual relate only to C and PASCAL.
  7608. REXX/2 can use routines in OS/2 DLLs, but I don't see any references
  7609. to those things in the manual. And, unlike RFROMPC, it's not a .EXE
  7610. file, so that our REXX/2 program can't just call it externally (or
  7611. so I think).
  7612.  
  7613. And before anyone else asks, we can't use RFROMPC, because the PS/2 file
  7614. | will contain only new sales order data on each incoming sales order.
  7615. Using RFROMPC will cause an OVERWRITE of the member on the AS/400; We
  7616. need to APPEND in that case. Sending to a data queue is better, since
  7617. their AS/400 CL programs can then process them off the queue, and
  7618. avoid obliterating any previous sales order data.
  7619.  
  7620. So my questions are: How does one use these APIs in a language other
  7621. than C and PASCAL? In particular, how does one use them with REXX/2?
  7622. Any one else have experience in using REXX/2 and PC Support APIs have
  7623. any comments to make on this?
  7624.  
  7625. Thanks in advance for your comments!
  7626.  
  7627. Art S. Liu (ALIU @BOSTON)
  7628. IBM Services Company
  7629. Client Server Practice
  7630. Waltham, MA
  7631.  
  7632. ----- OS2REXX CFORUM appended at 20:19:53 on 92/10/08 GMT (by VOYAGER at GDLVM7)
  7633. Subject: Can I use PC Support APIs in REXX program?
  7634. Ref:     Append at 20:10:26 on 92/10/08 GMT (by ALIU at BOSTON)
  7635.  
  7636. The first solution that comes to mind is to write an
  7637. program in C or PASCAL that uses the APIs, and can
  7638. be called from REXX.
  7639.  
  7640. Another solution would be to create a DLL containing
  7641. new functions that use the APIs, then register these
  7642. with REXX.
  7643.  
  7644. Robert Maiolini
  7645.  
  7646. ----- OS2REXX CFORUM appended at 22:20:44 on 92/10/08 GMT (by DEV2625 at HONE83)
  7647. Subject: Passing a stem variable to an external function . . .
  7648. Ref: Append at 16:12:54 on 92/09/25 GMT (by STHOWELL at DALHQIC2)
  7649.  
  7650. As extensions to our product we pass the base of the complex
  7651. to a C extension in a Dll. Once we have the name, we loop through
  7652. the RexxVariablePool which returns all variables from the root.
  7653.  
  7654. Frank V. Castellucci ¢COL Systems|
  7655.  
  7656. ----- OS2REXX CFORUM appended at 01:04:06 on 92/10/09 GMT (by AAAF0CY at OS2CUST)
  7657. Subject: VREXX and OOREXX
  7658. Ref: Append at 20:56:38 on 92/09/30 GMT (by BONILLA at KGNVMZ)
  7659.  
  7660. As an IBM customer, I appreciate the effort being put forth to bring
  7661. some of these programs to us. Internally, IBM has some of the
  7662. brightest minds around and you hit it on the head when you said these
  7663. types of products give IBM a competitive advantage. Just keep them
  7664. coming!!!!
  7665.  
  7666. Jim Sauber, MN Mutual
  7667.  
  7668. ----- OS2REXX CFORUM appended at 01:11:26 on 92/10/09 GMT (by AAAF0CY at OS2CUST)
  7669. Subject: Starting objects serially
  7670. Ref: Append at 19:12:31 on 92/09/25 GMT (by XXMUTL27 at TORVMCOP)
  7671.  
  7672. We have been trying to do this exact thing too for the exact same
  7673. reasons. I talked with IBM development and there response was that
  7674. the SysCreateObject call didn't work this way. I then went looking in
  7675. other directions and came across a program called STARTD in
  7676. STARTD.ZIP. It is a C pgm that does the same thing, but allows you to
  7677. create the window as a child window so that the parent will be
  7678. notified when the child terminates. Unfortunately, this works only
  7679. for OS/2 windows and not DOS windows. I am pursuing this now and will
  7680. try to let you know what I find.
  7681.  
  7682. Jim Sauber, MN Mutual
  7683.  
  7684. ----- OS2REXX CFORUM appended at 13:25:53 on 92/10/09 GMT (by ALIU at BOSTON) -
  7685. Subject:What Forum to append to? RE: PC/Support APIs & REXX/2
  7686.  
  7687. Hi,
  7688.  
  7689. It seems I've appended to inappropriately to this forum (Apologies
  7690. to the readers for the inappropriateness of the question here...)
  7691.  
  7692. Can someone recommend an appropriate FORUM for this question???
  7693. Replies to my reader if you wish to contact me offline on this.
  7694.  
  7695. Art S. Liu (ALIU @BOSTON)
  7696. IBM Services Company
  7697. Client Server Practice
  7698. Waltham, MA
  7699.  
  7700. ----- OS2REXX CFORUM appended at 14:34:00 on 92/10/09 GMT (by SBCY006 at OS2CUST)
  7701. Subject: Rexx Procedure run from the CONFIG.SYS
  7702.  
  7703. We a have a LOGIN.EXE program we have been calling frmo the CONFIG.SYS for
  7704. people to use when they login to our Netware server. We put it in the CONFIG.SY
  7705. S so that they would be logged in before the startup folder runs. The
  7706. problem was if they made a mistake on Login then the process ended and startup
  7707. continued. I wrote a small Rexx that gave them three tries and some information
  7708. on what they did wrong. My problem now is that I am having a problem running a
  7709. Rexx procedure from the CONFIG.SYS. I did try a
  7710. CALL=D:\OS2\CMD.EXE /K "LOGME.CMD"
  7711. but the /K parm did not work and the Rexx procedure was not called. I did get a
  7712. CMD session but I could not even run the rexx manually for some reason.
  7713.  
  7714. Two Questions
  7715. 1) Can I get a Rexx Procedure to run from the CONFIG.SYS
  7716. 2) How ?
  7717.  
  7718. Matthew Moran- County of Santa Barbara - SBCY006/HONE83
  7719.  
  7720. ----- OS2REXX CFORUM appended at 14:47:01 on 92/10/09 GMT (by MRTOM at YKTVMV)
  7721. ..... OS2REXX CFORUM modified at 14:59:34 on 92/10/10 GMT (by MRTOM at YKTVMV)
  7722. Subject: Rexx Procedure run from the CONFIG.SYS
  7723. Ref:     Append at 14:34:00 on 92/10/09 GMT (by SBCY006 at OS2CUST)
  7724.  
  7725. | What the *heck* am I thinking about?  As pointed out below, REXX is
  7726. | not active until the OS/2 shell comes up.  You can't run a REXX
  7727. | program from CONFIG.SYS.
  7728.  
  7729. | I have a non-REXX program that gets run from the CONFIG.SYS as follows:
  7730.   CALL=D:\OS2\CMD.EXE /C CORELOCK.CMD
  7731. This works.  I wouldn't think that the differences from your example
  7732. (/C instead of /K, no quotes) would make any difference, but try it
  7733. this way and see if it helps.  Also note that running programs via
  7734. CMD.EXE this way can act strangely on XGA systems;  the actual results
  7735. can range from spurious error messages during CONFIG.SYS processing to
  7736. the system refusing to boot.
  7737.  
  7738. Tom Bridgman
  7739. CORE and OS/2 Services - Watson
  7740.  
  7741. ----- OS2REXX CFORUM appended at 18:11:51 on 92/10/09 GMT (by FRMLSPA at HONE84)
  7742. Subject: How to delete entries from OS2SYS.INI
  7743. Ref: Append at 22:29:12 on 92/07/08 GMT (by XXMINC08 at TORVMCOP)
  7744.  
  7745. There is also a program EDTINI on the OS2BBS which lets you open
  7746. and edit your OS2.INI and OS2SYS.INI (delete being one of the options).
  7747. I haven't used it to change anything, just to "look around".
  7748.  
  7749. Scott Atwell - Analyst Programmer - Farmland Industries, Kansas City, MO
  7750.  
  7751. ----- OS2REXX CFORUM appended at 18:12:20 on 92/10/09 GMT (by FRMLSPA at HONE84)
  7752. Subject: Starting a REXX procedure from a DOS session
  7753. Ref: Append at 15:02:49 on 92/07/14 GMT (by CS04116 at OS2CUST)
  7754.  
  7755. You can start a DOS session from an OS/2 session but not vice-versa.
  7756. It would be possible to have a .CMD file kick off DOS sessions and a REXX program.
  7757. The only other approach I can think of is to start an OS/2 process
  7758. which is just a batch file which loops checking for the existance of
  7759. a particular file.  Have your DOS session create the "flag file" and the
  7760. looping batch file kick off the REXX task when the file exists (and take
  7761. care of deleting it so it doesn't continually keep starting your REXX
  7762. program.
  7763.  
  7764. Scott Atwell - Analyst Programmer - Farmland Industries, Kansas City, MO
  7765.  
  7766. ----- OS2REXX CFORUM appended at 19:22:21 on 92/10/09 GMT (by CTRIPP at CARVM3)
  7767.  
  7768. Subject: PM Applications
  7769.  
  7770. Does anyone have an interest/requirement to
  7771. develop PM applications using REXX?
  7772.  
  7773. If so, please send me a note at USIBMKSA @ IBMMAIL or
  7774. through Internet to CJONES @ CARVM3.VNET.IBM.COM
  7775.  
  7776. Thanks in advance............
  7777.  
  7778. CHUCK TRIPP
  7779. IBM PRGS
  7780. UI Tools Technical Office
  7781. Cary, NC 27511
  7782.  
  7783. Phone: 919-469-6551
  7784.  
  7785. ----- OS2REXX CFORUM appended at 21:15:02 on 92/10/09 GMT (by V$IGREGO at BCRVM7)
  7786. Subject: RC(1002)
  7787.  
  7788. I am getting this RC(1002) error from rexx.  The program has run before
  7789. without any problem... Any ideas any one ? Chris
  7790.  
  7791. ----- OS2REXX CFORUM appended at 21:49:41 on 92/10/09 GMT (by XXNOVA24 at TORVMCOP)
  7792. Subject: PM Applications
  7793. Ref:     Append at 19:22:21 on 92/10/09 GMT (by CTRIPP at CARVM3)
  7794.  
  7795. Since I can't send messages across the border, I'm posting it here.
  7796. For quick and dirty apps, I'm interested in V-PM-Rexx
  7797.  
  7798. Geza Szivos
  7799. NOVACOR Chemicals  (403)-290-6583 Fax (403)-290-5900
  7800. NHO-32 801-7th Ave Calgary, Alberta, CANADA T2P 2N6
  7801.  
  7802. ----- OS2REXX CFORUM appended at 22:29:11 on 92/10/09 GMT (by FCOC079 at OS2CUST)
  7803. Subject: RC(1002)
  7804. Ref: Append at 21:15:02 on 92/10/09 GMT (by V$IGREGO at BCRVM7)
  7805.  
  7806. In what context are you getting the error?  Issuing an environment (OS/2)
  7807. command from within a Rexx program?  Trying to invoke your Rexx program?
  7808. ????
  7809.  
  7810. Dave Boll
  7811.  
  7812. ----- OS2REXX CFORUM appended at 00:09:44 on 92/10/10 GMT (by BCHI040 at HONE81)
  7813. Subject: VREXX2 Problems, Access violation VREXX.DLL
  7814. Ref: Append at 00:10:44 on 92/10/08 GMT (by IL41468 at HONE84)
  7815.  
  7816. Thanks,  That seemd to help. But I still have some questions
  7817.  
  7818. 1. If the REXX ABENDS due to syntax error and I must reboot to run again.
  7819.  
  7820. 2. If I set the SIGNAL on Syntax name Cleanup VExit is called and I have no
  7821.    debug syntax error messages and I still get a SYS3170 error
  7822.  
  7823. 3. Is there any other way to reset or release the VREXX.DLL
  7824.  
  7825. I really like the functions that VREXX offer I just wish they were integrated into
  7826. REXX a little better.
  7827.  
  7828. Jerry Hittle Hawaii Medical Service Assn.
  7829.  
  7830. ----- OS2REXX CFORUM appended at 00:15:41 on 92/10/10 GMT (by AMBC006 at MARTLINK)
  7831. Subject: Rexx Procedure run from the CONFIG.SYS
  7832. Ref: Append at 14:47:01 on 92/10/09 GMT (by MRTOM at YKTVMV)
  7833.  
  7834. If you are running a Rexx exec from the Config.sys I would be extremely
  7835. interested in knowing how you're doing it.  I have been able to execute
  7836. command files (inisave.cmd and the like) but unless something has changed
  7837. recently I've never been able to execute a Rexx exec.  I define a Rexx
  7838. exec as a command file that has a /* */ in the first line.  Until recently
  7839. I've kept a simple 'hello.cmd' in my config.sys that simply redirect the
  7840. output of a 'Say "hello" time()' to a file, and I never found my hello line.
  7841. I thought that rexx wasn't available until the startup went thru the
  7842. 'LoadOneTime' of the SYS_DLLS for REXXINIT.  I've considered using the
  7843. Rexinit.EXE that came in the Remote Installation to get rexx running but
  7844. haven't had the time -- yet.
  7845.  
  7846. Michael Suszko, Jr (A. M. Best Co., Oldwick NJ)
  7847.  
  7848. ----- OS2REXX CFORUM appended at 23:17:37 on 92/10/10 GMT (by FFX1016 at OS2CUST)
  7849. Subject: VREXX2: Good Job
  7850.  
  7851. I've just started playing with VREXX2 and I think is one of the best
  7852. things that happened to OS/2 since going 32bit. I think this product
  7853. should become a part of the base system and fully supported. It seems
  7854. to be the most logical extension of OS/2 base system. I'am using
  7855. VREXX to convince our sys programmers how easy OS/2
  7856. installation/customization is! Hope you keep improving on this. Thanks.
  7857.  
  7858. Sanjay Jeer
  7859.  
  7860. ----- OS2REXX CFORUM appended at 09:55:18 on 92/10/11 GMT (by G13 at TELVM1) --
  7861. Subject: COBOL program registration
  7862.  How do i register a COBOL (either DLL or EXE) program as an
  7863. external function to be called from REXX ?? Has a COBOL program
  7864. to indicate somehow in its source that it is going to be used as
  7865. an external function ? An example, please ! ! !
  7866.   Thanks in advance,
  7867.           Eugene Deborin.
  7868.  
  7869. ----- OS2REXX CFORUM appended at 18:49:22 on 92/10/11 GMT (by FCOC079 at OS2CUST)
  7870. Subject: COBOL program registration
  7871. Ref: Append at 09:55:18 on 92/10/11 GMT (by G13 at TELVM1) --
  7872.  
  7873. Nothing special needs to be done.  If your external function is a DLL, just
  7874. register it by using the RxFuncAdd function.  If your external function is an
  7875. EXE, use the RexxRegisterFunctionEXE call from within your code.  What COBOL
  7876. are you using, MicroFocus ???
  7877.  
  7878. Dave Boll
  7879.  
  7880. ----- OS2REXX CFORUM appended at 10:20:26 on 92/10/12 GMT (by 70653267 at EHONE)
  7881. Subject: REXX macro space execution
  7882. I'm running under 1.3
  7883. My Goal is to execute a REXX Function in the Macro Space.
  7884. I generated a Macro Lib File "SAVE.CMD" with RxMacroSave, it works Fine |
  7885. (This Lib File contains one Function "RXTEST".
  7886. I loaded this File and the "RXTEST" test Function with RxMacroLoad,
  7887. it works Fine |
  7888. Now I'm trying to execute this "RXTEST" function with the REXXSAA func.
  7889. Unfortunately it does not work. The return code is always -3.
  7890. here is my Code :
  7891.  
  7892.  src = RxMacroErase();
  7893.  src = RxMacroLoad (0,NULL,"SAVE.CMD");
  7894.  
  7895.  src=REXXSAA ( (SHORT)      1,
  7896.              (PRXSTRING)  arg,
  7897.              (PSZ)        "RXTEST",
  7898.              (PRXSTRING)  NULL,
  7899.              (PSZ)        NULL,
  7900.              (SHORT)      RXFUNCTION,
  7901.              (PRXSYSEXIT) NULL,
  7902.              (PSHORT)     &srexxrc,
  7903.              (PRXSTRING)  &rexxretval );
  7904.  
  7905. What have I missed ?
  7906. thanks in advance for your help
  7907.  
  7908. ----- OS2REXX CFORUM appended at 11:19:33 on 92/10/12 GMT (by SBSTBEG at OS2CUST)
  7909. Subject: PM Applications
  7910. Ref: Append at 19:22:21 on 92/10/09 GMT (by CTRIPP at CARVM3)
  7911.  
  7912. Since acquiring VREXX, I have become interested in PM programming in
  7913. REXX.  VREXX has made it possible to make quick and dirty PM
  7914. programs.
  7915.  
  7916. Bill Stephens
  7917.  
  7918. ----- OS2REXX CFORUM appended at 11:57:28 on 92/10/12 GMT (by WZ00533 at LINK21)
  7919. Subject: PM Applications
  7920. Ref: Append at 19:22:21 on 92/10/09 GMT (by CTRIPP at CARVM3)
  7921.  
  7922. Chuck,
  7923.  
  7924. I will try to send this reponse to your IBMMAIL address, but
  7925. I will also state here that I would like to create PM apps in
  7926. REXX.  I don't expect to create 'production' apps, rather I
  7927. think REXX would be a create rapid prototyping tool.  Also I
  7928. believe we can use it as a general purpose utiltity language.
  7929. Go for it!!!
  7930.  
  7931. Dave Ferrey - Bethlehem Steel Corp. Bethlehem PA.
  7932.  
  7933. ----- OS2REXX CFORUM appended at 12:35:09 on 92/10/12 GMT (by PRICESG at GDLVM7)
  7934. Subject: REXX macro space execution
  7935. Ref:     Append at 10:20:26 on 92/10/12 GMT (by 70653267 at EHONE)
  7936.  
  7937. The REXXSAA function does not have the ability to invoke programs
  7938. from the macrospace.  In a 16-bit environment, macrospace programs
  7939. may only be called as REXX functions or subroutines.
  7940.  
  7941. RexxStart, the 32-bit equivalent, _does_ permit invocation of
  7942. macrospace routines.
  7943.  
  7944. Steve Price        SAA REXX Development
  7945.  
  7946. ----- OS2REXX CFORUM appended at 14:33:36 on 92/10/12 GMT (by SBCY006 at OS2CUST)
  7947. Subject: Rexx Procedure run from the CONFIG.SYS
  7948. Ref: Append at 14:47:01 on 92/10/09 GMT (by MRTOM at YKTVMV)
  7949.  
  7950. I didn't mean to imply that I am currently doing this but I have a need to
  7951. do this. I sounds like since the Shell is up yet that it won't work. I am
  7952. not doing anything fancy in my Rexx Procedure except for a SELECT which I
  7953. can get rid of and also some RC checking. Can I do RC checking in a "normal"
  7954. command file under OS/2 to solve my problems.
  7955.  
  7956. Matthew Moran- County of Santa Barbara - SBCY006/HONE83
  7957.  
  7958. ----- OS2REXX CFORUM appended at 15:00:58 on 92/10/12 GMT (by IL22868 at HONE83)
  7959. Subject: Rexx Procedure run from the CONFIG.SYS
  7960. Ref: Append at 14:33:36 on 92/10/12 GMT (by SBCY006 at OS2CUST)
  7961.  
  7962. Try the ERRORLEVEL keyword.  It is not as convenient to use as Rexx's RC, but
  7963. with some effort, it can do the job.  ERRORLEVEL should be described in DOS
  7964. BAT and OS/2 CMD references (the online OS/2 Command Reference).
  7965.  
  7966. ----- OS2REXX CFORUM appended at 20:54:43 on 92/10/12 GMT (by V$IGREGO at BCRVM7)
  7967. Subject: RC(1002)
  7968. Ref:     Append at 22:29:11 on 92/10/09 GMT (by FCOC079 at OS2CUST)
  7969.  
  7970. I get this error when issuing an OS2 environment variable command from
  7971. within a REXX command file.
  7972. Re-booting eliminated all errors, though.  I'm still curious as to
  7973. why the error occurred.  Christian
  7974.  
  7975. ----- OS2REXX CFORUM appended at 06:49:41 on 92/10/13 GMT (by IL78711 at OS2CUST)
  7976. Subject: VREXX2: Good Job
  7977. Ref: Append at 23:17:37 on 92/10/10 GMT (by FFX1016 at OS2CUST)
  7978.  
  7979. I mentioned several weeks ago that I thought that VREXX should be added to
  7980. the OS/2 base. Hopefully if IBM gets plenty of feedback they will see its
  7981. obvious competitive advantages. I will be very surprised if thy
  7982.  
  7983.  not add
  7984. it to the product. It looks like such a low cost addition it should be  a
  7985. no-brainer!?
  7986.  
  7987. ----- OS2REXX CFORUM appended at 15:00:42 on 92/10/13 GMT (by PPBKR at HONE84)
  7988. Subject: REXX20 - DLL replacement
  7989. Ref: Append at 06:49:41 on 92/10/13 GMT (by IL78711 at OS2CUST)
  7990.  
  7991. I have developed a REXX program that will get executed every
  7992. time someone logs into our Novell server.  This REXX program
  7993. utilizes several new commands contained in the REXX20 upgrade.
  7994. Unfortunately, most of our users haven't installed the REXX20
  7995. DLL's.  So, I've written a small procedure that checks the
  7996. date on their REXX.DLL, REXXAPI.DLL, REXXINIT.DLL, and REXXUTIL.DLL.
  7997. If they don't have the correct DLL's, I copy a self extracting ZIP
  7998. file to their \OS2\DLL subdirectory and ask the user to boot to
  7999. their installation diskettes, change to \OS2\DLL, unzip the
  8000. new DLL's, then reboot.
  8001.  
  8002. This procedure can be difficult/annoying for a lot of our users
  8003. (booting to an OS/2 boot disk or to the installation diskettes is
  8004. the annoying part).
  8005.  
  8006. 2 questions:
  8007.  
  8008. 1) In my limited C/2 DLL development, I've always included a KILLDLL
  8009.    routine, which I could Call to cause my DLL to TRAP D (ie, unload),
  8010.    so I could re-compile, etc.  I don't suppose any of these REXX DLL's
  8011.    contain a similar function?
  8012.  
  8013. 2) Is there any other way to copy these DLL's to \OS2\DLL without booting
  8014.    to another system?  For example: calling a .CMD file from the CONFIG.SYS
  8015.    that would copy these DLL's before REXX loads?
  8016.  
  8017. Thanks in advance!
  8018.  
  8019. Brian Surdahl, Phillips Petroleum Co.
  8020.  
  8021. ----- OS2REXX CFORUM appended at 09:19:16 on 92/10/14 GMT (by G13 at TELVM1) --
  8022. =========================================================================
  8023. Subject: COBOL/2 program as REXX external function
  8024.   Dave,
  8025. I am trying to use a COBOL program as a REXX external function. The COBOL
  8026. is IBM COBOL/2 (the highest level we have got before IBM stopped to market it).
  8027. The program is beeing linked as a DLL and gets registered by RxFuncAdd. That
  8028. is OK.
  8029. The problem is that when the program is beeing invoked by REXX it starts
  8030. working (i see it with display commands) but when doing a GOBACK REXX gets
  8031. an access violation and the session bumps out.
  8032. Another problem (probably it is the same one) is that i can not find my input
  8033. parameters. The LINKAGE SECTION of a COBOL problem gets 256 in its first
  8034. word(that could be a length of RXSTRING) and valid address in its second
  8035. word. I expected to find my input data at that address, but it was not
  8036. there.
  8037. To sum it up, how are the REXX program parameters (let us say only one
  8038. parameter) passed to a COBOL program and how it is supposed to get them
  8039. and return the answer ?
  8040.  
  8041.       Thanks again,
  8042.                Eugene Deborin,
  8043.                        IBM Jerusalem Israel.
  8044.  
  8045. ----- OS2REXX CFORUM appended at 13:47:19 on 92/10/14 GMT (by FCOC079 at OS2CUST)
  8046. Subject: as REXX external function
  8047. Ref: Append at 09:19:16 on 92/10/14 GMT (by G13 at TELVM1) --
  8048.  
  8049. I don't know how close COBOL/2 is to recent MicroFocus (I heard that
  8050. COBOL/2 is one of MicroFocus' older versions), but assuming the
  8051. features that follow are supported, here's how I got it to work
  8052. (in retrospect, I think this could have been done more easily):
  8053.  
  8054. /
  8055.  Working-Storage Section.
  8056. *--- Rexx External Function Parameter List (EFPL)
  8057.  01  IRXEFPL-Func-Name            Pic x(8).
  8058.  01  IRXEFPL-Arg-Count            Pic s9(4) Comp-5.
  8059.  01  IRXEFPL-Arg-Array-Pointer    Pointer.
  8060.  01  IRXEFPL-Queue-Name           Pointer.
  8061.  01  IRXEFPL-EvalBlock-Addr       Pointer.
  8062.  01  RxString.
  8063.      05  RxString-Len             Pic s9(9) Comp-5.
  8064.      05  RxString-Ptr             Pointer.
  8065. *--- Rexx Argument List
  8066.  01  IRXEFPL-Arg-List.
  8067.      05  IRXEFPL-Arg-Pair         Occurs 20 Times.
  8068.          10  IRXEFPL-Arg-Len      Pic s9(9) Comp-5.
  8069.          10  IRXEFPL-Arg-Ptr      Pointer.
  8070. *--- Result Buffer RXSTRING
  8071.  01  IRXEFPL-Result.
  8072.      05  IRXEFPL-Result-Len       Pic  9(9) Comp-5.
  8073.      05  IRXEFPL-Result-Ptr       Pointer.
  8074.  
  8075. /
  8076.  Linkage Section.
  8077.  01  Work-Buf                     Pic x(32765).
  8078.  01  Result-Buf                   Pic x(250).
  8079.  
  8080. ...
  8081.  
  8082. /
  8083.  Procedure Division OS2API Using
  8084.              By Reference IRXEFPL-Func-Name
  8085.              By Value     IRXEFPL-Arg-Count
  8086.                           IRXEFPL-Arg-Array-Pointer
  8087.                           IRXEFPL-Queue-Name
  8088.                           IRXEFPL-EvalBlock-Addr.
  8089. *--- Get Arg # 1 as supplied by calling Rexx program
  8090.      If IRXEFPL-Arg-Count >= 1 Then
  8091.        If IRXEFPL-Arg-Len(1) > Zero Then
  8092.          Set Address Of Work-Buf To IRXEFPL-Arg-Ptr(1)
  8093.          Display 'Arg 1 is "' Work-Buf(1:IRXEFPL-Arg-Len(1)) '"'
  8094.        Else
  8095.          Display 'Arg 1 was supplied but was zero length'
  8096.        End-If
  8097.      Else
  8098.        Display 'Arg 1 was not supplied'
  8099.      End-If
  8100.  
  8101. *--- Base EFPL Evaluation Block to return information to Rexx program
  8102. *    (use the 250 bytes the Rexx interpreter gives us by default, though
  8103. *     we could allocate our own storage if we needed more)
  8104.      Set Address Of IRXEFPL-Result
  8105.       To IRXEFPL-EvalBlock-Addr
  8106.      Set Address Of Result-Buf
  8107.       To IRXEFPL-Result-Ptr
  8108.      Move Zero To IRXEFPL-Result-Len
  8109.      String 'Here''s a response from the external function'
  8110.        Delimited By Size
  8111.        Into  Result-Buf
  8112.        With Pointer IRXEFPL-Result-Len
  8113.  
  8114.      GoBack.
  8115.  
  8116. Hope this helps, RSVP if questions, etc.
  8117.  
  8118. Dave Boll
  8119.  
  8120. ----- OS2REXX CFORUM appended at 21:56:15 on 92/10/14 GMT (by 347258 at DALVM21)
  8121. Subject: OS2 1.3 AND OS2 2.0 STREAM IO RESTRICTIONS
  8122. Does anyone know if os2 1.3 has any restriction for the number of times
  8123. you can "close" the same file name within the same program.  I am
  8124. closing a file a large number of times and my code runs fine under
  8125. os2/2.0.  When I port to OS2 1.3 machine, I get different results.
  8126. It seems that I might be at end of file after I do a close.  I am
  8127. hoping the close will assure that I am always starting at the top
  8128. of the file with command  junk = stream(outfile,c,'close')
  8129.  
  8130. I have also found that in OS2 2.0 if I do not close a file initially
  8131. before I use it for the very first time, the return code lines(myfile)
  8132. = 0 at times
  8133. and my program will end as if no data exists in the file, when really
  8134. there is data in the file.
  8135.   junk = stream(myfile,c,'close')
  8136.   do until lines(myfile)=0
  8137.   end
  8138.   /* then I delete myfile and create it again using lineout cmd */
  8139. Could anyone tell me why it might be necessary for me to close a
  8140. file before I use it even though it could not possibly be at eof since
  8141. I have not used it yet.Thanks in advance!
  8142. K. Kovach (301)571-2211 Bethesda,MD  DEM II
  8143.  
  8144. ----- OS2REXX CFORUM appended at 17:19:18 on 92/10/15 GMT (by PWIS110 at OS2CUST)
  8145. Subject: LAUNCHING DOS FROM REXX
  8146.  
  8147. Is there an easy way to launch a DOS program from a menu
  8148. displayed by a REXX procedure in OS/2 2.0?  Currently, the
  8149. DOS program runs successfully by clicking on an icon from
  8150. the desktop.  The DOS settings for this object were
  8151. altered to give the application more expanded memory, more
  8152. files, etc.  Is it possible to have Rexx launch this
  8153. program (or its pgm-object) so that its DOS settings are
  8154. recognized?  If it IS possible to do this, what happens
  8155. when the user presses ALT+ESC after the DOS program gets
  8156. launched?  Will the focus return to the OS/2 DESKTOP, the
  8157. REXX exec, or other?
  8158.  
  8159. G. Monico
  8160.  
  8161. ----- OS2REXX CFORUM appended at 17:57:56 on 92/10/15 GMT (by CNADLER at WMAVM1)
  8162. Subject: LAUNCHING DOS FROM REXX
  8163. Ref:     Append at 17:19:18 on 92/10/15 GMT (by PWIS110 at OS2CUST)
  8164.  
  8165. 1) You can use the SysCreateObject function of the latest REXX20 utils
  8166.    to start the program object, if you know it's ID (it's best to
  8167.    create it yourself.
  8168. 2) Using this, the REXX CMD file will continue to run after it starts the
  8169.    DOS program.
  8170. 3) I don't know where it would return to, but I suspect the desktop.
  8171.  
  8172. See Mike Lamb's append from near the beginning of this forum for details
  8173. of the SysCreateObject call and how to start objects (with settings).
  8174.  
  8175. Cliff Nadler                                         GO TEAM OS/2!
  8176. Systems Integration and Services                     Rockville, MD
  8177. IBM Federal Systems Company                PROFS: NADLER at WMAVM7
  8178.  
  8179. ----- OS2REXX CFORUM appended at 18:11:30 on 92/10/15 GMT (by ROK2027 at HONE82)
  8180. Subject: Changing a Files date/time stamp ?
  8181.  
  8182. Is there a function in rexx that will allow a files date and time stamps to be
  8183. changed...?
  8184.  
  8185. I have a user who has an application in which they want the date/time stamp for
  8186. the applications created/updated files to have a date/time that will easily
  8187. indicate when they were last changed if such a change was by something outside
  8188. the application.
  8189.  
  8190. ----- OS2REXX CFORUM appended at 05:59:36 on 92/10/16 GMT (by XXNOVA24 at TORVMCOP)
  8191. Subject: Moving folders.
  8192. How can I move (!) one folder into another one?
  8193. I mean from REXX. With RMB is easy.
  8194. This is part of a costumization program, I'd like to collect ALL of the
  8195. ES, CM,LAN ,... folders to a Main folder.
  8196. I knew the current location <..._FOLDER> and the target <MAIN_FOLDER>.
  8197. I'm sure it can be done, but how?
  8198.  
  8199. Geza Szivos
  8200. NOVACOR Chemicals  (403)-290-6583 Fax (403)-290-5900
  8201. NHO-32 801-7th Ave Calgary, Alberta, CANADA T2P 2N6
  8202.  
  8203. ----- OS2REXX CFORUM appended at 06:29:14 on 92/10/16 GMT (by THRUMD at SYDVM1)
  8204. Subject: Moving folders.
  8205. Ref:     Append at 05:59:36 on 92/10/16 GMT (by XXNOVA24 at TORVMCOP)
  8206.  
  8207. The MOVE command should do the trick if you are moving within the same
  8208. drive.
  8209.  
  8210. Dave
  8211.  
  8212. ----- OS2REXX CFORUM appended at 15:48:05 on 92/10/16 GMT (by IL32772 at OS2CUST)
  8213. Subject: PM Applications
  8214. Ref: Append at 19:22:21 on 92/10/09 GMT (by CTRIPP at CARVM3)
  8215.  
  8216. We do have interest in developing PM apps with rexx.  I can provide some ideas
  8217. as to our expectations if this will help.  Please feel free to phone, since the
  8218.  items are extensive.
  8219.  
  8220. Randy Cairns Systems Coordinator  (515) 245-2322
  8221.  
  8222. ----- OS2REXX CFORUM appended at 14:59:03 on 92/10/20 GMT (by JERKEWIT at DALVM41B)
  8223. Subject:SysFileTree not Finding $ Files
  8224.  
  8225. I have written a small C procedure to validate DosFindFirst2 and
  8226. DosFindFirst.  I get the expected results. This appears to be an insect
  8227. in SysFileTree. Is this the correct place for this, or should I call
  8228. Level 1 support?  Any help will be welcome.
  8229.  
  8230.  Thanx...
  8231. Peter Jerkewitz @ DALVM41B
  8232.  
  8233. ----- OS2REXX CFORUM appended at 15:59:07 on 92/10/20 GMT (by NIBMC302 at RALVMG)
  8234. Subject: RexxStart
  8235. By: Dave Collom
  8236.  
  8237.    I think that the problem I may be having is that I am tryin to call
  8238.  RexxStart from a PM application.  I am getting a RC of -48 which maps
  8239.  to "Failure In System Service" and it seems to be related to stdin and
  8240.  stdout.  Has anyone seen this, and have any idea what to do about it?
  8241.  I suppose I could start a straight OS/2 process (using DosExecPgm) that
  8242.  calls RexxStart but that seems like a lot of overhead.
  8243.  
  8244.                                                   Thanks,
  8245.                                                       Dave Collom
  8246.                                                       NIBMC302 at RALVMG
  8247.                                                       OSI Tools Dev.
  8248.                                                       RTP, NC
  8249.  
  8250. ----- OS2REXX CFORUM appended at 17:30:29 on 92/10/20 GMT (by F0JASKUS at DCTVM1)
  8251. Subject: SysCreateObject( 'WPPrinter', ...) ?
  8252.  
  8253.    I would like to create a WPPrinter object on the desktop. I want
  8254. to use the SysCreateObject function. Is it possible? I think there
  8255. are some secial Setup String keynames/values to define the printer.
  8256. Does anybody know it?
  8257.  
  8258. Christophe JAGUSIAK
  8259.  
  8260. ----- OS2REXX CFORUM appended at 13:07:33 on 92/10/21 GMT (by HDEVORE at BOULDER)
  8261. Subject: Re: SysCreateObject( 'WPPrinter', ...) ?
  8262. Ref:     Append at 17:30:29 on 92/10/20 GMT (by F0JASKUS at DCTVM1)
  8263.  
  8264. >   I would like to create a WPPrinter object on the desktop. I want
  8265. >to use the SysCreateObject function. Is it possible?
  8266.  
  8267. I don't think you can create a printer object in this manner.  Printer
  8268. objects are created as a byproduct or creating a queue.  I read
  8269. something about this recently and will try to find the information.
  8270.  
  8271. Hal DeVore                       Space Station DMS Software Development
  8272. HDEVORE at HOUVMSCC                       hdevore@houvmscc.vnet.ibm.com
  8273.  
  8274. ----- OS2REXX CFORUM appended at 19:05:54 on 92/10/21 GMT (by ROK2027 at OS2CUST)
  8275. ..... OS2REXX CFORUM modified at 20:05:39 on 92/10/21 GMT (by ROK2027 at OS2CUST)
  8276. and Fonts
  8277. This APPEND was deleted at 16:05:38 on 10/21/92 EST.
  8278.  
  8279. ----- OS2REXX CFORUM appended at 20:08:47 on 92/10/21 GMT (by ROK2027 at OS2CUST)
  8280. Subject: VREXX and Fonts
  8281.  
  8282. I am attempting to put up a table using the VREXX VTableBox function
  8283. and have noticed that it uses proportional fonts.  The VSetFont is fine
  8284. if you have a window-id, but that means you have to open a window and
  8285. (apparently) put the data into it yourself.  VTableBox creates the table
  8286. using stem variables very nicely.
  8287.  
  8288. 1.  How can one change the fonts for the table contents in the
  8289.     VTableBox display?
  8290.  
  8291. 2.  What is the correct forum for reporting 'bugs' with VREXX and
  8292.     for asking questions.
  8293.  
  8294. btw.  here is the rexx application that I am trying to work with if you
  8295. want to try it:
  8296.  
  8297. /* rexx */
  8298.  
  8299. call RxFuncAdd 'VInit', 'VREXX', 'VInit'
  8300.  
  8301. call RxFuncAdd 'SysLoadFuncs', 'RexxUtil', 'SysLoadFuncs'
  8302.  
  8303. call SysLoadFuncs
  8304.  
  8305. Vinit_code = VInit()
  8306. if initcode = 'ERROR' then signal Clean_Up
  8307.  
  8308. Signal on failure name Clean_Up
  8309. Signal on halt    name Clean_Up
  8310. Signal on syntax  name Clean_Up
  8311.  
  8312. Local_Disks  = SysDriveMap('C:','LOCAL')
  8313. Remote_Disks = SysDriveMap('C:','REMOTE')
  8314.  
  8315. drives.0 = 1
  8316. table.1. = ''
  8317. table.1.1 = '***************'
  8318. table.1.2 = '***************'
  8319. table.1.3 = '***************'
  8320. table.1.4 = '***************'
  8321. table.1.5 = "Local Disks"
  8322.  
  8323. do i = 1 to words(local_disks)
  8324.    drive = word(local_disks,i)
  8325.    info = SysDriveInfo(drive)
  8326.    parse value info with disk free total name
  8327.    d = drives.0 + 1
  8328.    drives.0 = d
  8329.    table.d.1 = disk
  8330.    call fix_num free/1024
  8331.    table.d.2 = number"kb"
  8332.    call fix_num  (total-free)/1024
  8333.    table.d.3 = number"kb"
  8334.    call fix_num total/1024
  8335.    table.d.4 = number"kb"
  8336.    table.d.5 = strip(name)
  8337. end /* do */
  8338.  
  8339. d = drives.0 + 1
  8340. drives.0 = d
  8341. table.d. = ''
  8342. table.d.1 = '***************'
  8343. table.d.2 = '***************'
  8344. table.d.3 = '***************'
  8345. table.d.4 = '***************'
  8346. table.d.5 = "Remote Disks"
  8347.  
  8348. do i = 1 to words(Remote_disks)
  8349.    drive = word(remote_disks,i)
  8350.    info = SysDriveInfo(drive)
  8351.    parse value info with disk free total name
  8352.    d = drives.0 + 1
  8353.    drives.0 = d
  8354.    table.d.1 = disk
  8355.    call fix_num free/1024
  8356.    table.d.2 = number"kb"
  8357.    call fix_num  (total-free)/1024
  8358.    table.d.3 = number"kb"
  8359.    call fix_num total/1024
  8360.    table.d.4 = number"kb"
  8361.    table.d.5 = strip(name)
  8362. end /* do */
  8363.  
  8364. table.rows = drives.0
  8365. table.cols = 5
  8366. table.label.1 = "Disk"
  8367. table.label.2 = "Free Bytes"
  8368. table.label.3 = "Used Bytes"
  8369. table.label.4 = "Total Bytes"
  8370. table.label.5 = "Volume Label"
  8371. table.width.1 = 10
  8372. table.width.2 = 15
  8373. table.width.3 = 15
  8374. table.width.4 = 15
  8375. table.width.5 = 20
  8376.  
  8377. height = drives.0
  8378.  
  8379. call VTableBox 'Currently Active Drives',table,1,75,height,1
  8380.  
  8381. Clean_Up:
  8382.         call VExit
  8383.         call SysDropFuncs
  8384.  
  8385. exit 0
  8386.  
  8387. fix_num:
  8388. arg number
  8389.  
  8390. point = pos('.',number)
  8391. if point > 0 then len = point - 1
  8392.              else len = length(number)
  8393.  
  8394. numeric = format(len/3,,0)
  8395.  
  8396. offset = 3
  8397.  
  8398. do x = 1 to numeric
  8399.    location = len - offset
  8400.    if location < 1 then leave
  8401.    offset = offset + 3
  8402.    number = insert(',',number,location,1)
  8403.    end
  8404.  
  8405. return number
  8406.  
  8407. Lionel Dyck - Rockwell International, Information Systems Center
  8408.  
  8409. ----- OS2REXX CFORUM appended at 14:13:13 on 92/10/22 GMT (by MCGUIRE at GDLVM7)
  8410. Subject: RexxStart
  8411. Ref:     Append at 15:59:07 on 92/10/20 GMT (by NIBMC302 at RALVMG)
  8412.  
  8413. If you invoke a Rexx program with RexxStart, it runs in the same process as
  8414. your application.  For PM applications, this means that stdin and stdout don't
  8415. exist.  Output to stdout or stderr is just tossed into the bit bucket, but if
  8416. the program tries to read from stdin, it will receive an error.  You can
  8417. avoid this by rewriting the application to avoid the pull instruction or by
  8418. adding a PMREXX style I/O shell to handle the input and output.  You might want
  8419. to take a look at the PMREXX sample in the toolkit which shows how to do this.
  8420. The PMREXXIO.DLL can be easily adapted for other applications.
  8421.  
  8422. Rick McGuire - SAA Rexx Development, Endicott
  8423.  
  8424. ----- OS2REXX CFORUM appended at 14:53:20 on 92/10/22 GMT (by SC025203 at AUSVM8)
  8425. Subject: VREXX and Fonts
  8426. Ref:     Append at 20:08:47 on 92/10/21 GMT (by ROK2027 at OS2CUST)
  8427.  
  8428. Lionel,
  8429.  
  8430.   Just to answer your question about reporting "defects" in VREXX,
  8431. it is a tool developed under the IBM Employee Written Software (EWS)
  8432. program and as such is provided on the OS/2 BBS on an "as is" basis
  8433. only, no formal support by IBM is provided. However, this forum is
  8434. probably as good as any other to report problems with it that hopefully
  8435. will then get reported to the VREXX author.
  8436.  
  8437. Stephen Poole
  8438. OS/2 Service and Support - IBM Austin, TX
  8439.  
  8440. ----- OS2REXX CFORUM appended at 15:19:46 on 92/10/22 GMT (by DALNK03 at OS2CUST)
  8441. Subject: Adding a menu item to the Desktop
  8442.  
  8443. Is there a way in REXX to add a menu item to the OS/2 Desktop?  We would
  8444. like to be able to automate adding an OS/2 Command Window.
  8445.  
  8446. Pat Malneritch, Delta Air Lines
  8447.  
  8448. ----- OS2REXX CFORUM appended at 19:24:08 on 92/10/22 GMT (by HDEVORE at BOULDER)
  8449. Subject: Re: SysCreateObject( 'WPPrinter', ...) ?
  8450.  
  8451. >                                                         I read
  8452. >something about this recently and will try to find the information.
  8453.  
  8454. Well, I can't find it.  Someone just recently posted in one of our
  8455. internal FORUMS (=newsgroups, =BBS files) something to the effect that
  8456. a printer object is created by the spooler as a byproduct of the
  8457. SplCreateQueue() and SplCreateDevice calls.  Since, to my knowledge,
  8458. the SplXxx calls are not in any of the REXX function packages I think
  8459. you'll have to write C code to create new printer object.
  8460.  
  8461. Hal DeVore                                      Hal_DeVore@vnet.ibm.com
  8462. IBM Federal Systems Company      Space Station DMS Software Development
  8463.  
  8464. ----- OS2REXX CFORUM appended at 20:11:54 on 92/10/22 GMT (by WDRUMMON at NYCVMIC1)
  8465. ..... OS2REXX CFORUM modified at 01:03:40 on 92/10/23 GMT (by WDRUMMON at NYCVMIC1)
  8466. Removed by appender
  8467.  
  8468. ----- OS2REXX CFORUM appended at 21:24:39 on 92/10/22 GMT (by BRENT at DALVM41B)
  8469. Subject: VREXX and Fonts
  8470. Ref: Append at 20:11:54 on 92/10/22 GMT (by WDRUMMON at NYCVMIC1)
  8471.  
  8472. Come on IBMers.  Read the forum headers.  This forum (and all CForums)
  8473. are viewable by customers.  Internal forums are not.  Please don't refer
  8474. customers to forums they can't get to.
  8475.  
  8476. Brent Allen - IBM LAN Systems Integration Services     Southlake, TX
  8477.  
  8478. ----- OS2REXX CFORUM appended at 00:01:58 on 92/10/23 GMT (by IL11901 at OS2CUST)
  8479. Subject: Adding a menu item to the Desktop
  8480. Ref: Append at 15:19:46 on 92/10/22 GMT (by DALNK03 at OS2CUST)
  8481.  
  8482. Sounds like another CommandLine candiate.  Drop me
  8483. a note if you want to know more.
  8484.  
  8485. Arthur Goikhman -- Soft & GUI Inc
  8486.  
  8487. ----- OS2REXX CFORUM appended at 14:16:41 on 92/10/23 GMT (by HME0003 at OS2CUST)
  8488. Subject: VREXX and Fonts
  8489. Ref: Append at 20:08:47 on 92/10/21 GMT (by ROK2027 at OS2CUST)
  8490.  
  8491. Lionel,
  8492.  
  8493. I am having the same problem with VTableBox.  Sometimes I get the
  8494. non-proportional font that I would expect and other times I get the
  8495. proportional font that causes the misalignment of the columns.  In the
  8496. doc that comes with VREXX there appears to be no way of assigning a font
  8497. for VTableBox.  Any help on this matter would be appreciated.
  8498.  
  8499. Jeff Jaynes
  8500. Horace Mann Educators Corp.
  8501.  
  8502. ----- OS2REXX CFORUM appended at 17:09:26 on 92/10/23 GMT (by F0JASKUS at DCTVM1)
  8503. Subject: Re: SysCreateObject( 'WPPrinter', ...)
  8504. Ref:     Append at 19:24:08 on 92/10/22 GMT (by HDEVORE at BOULDER)
  8505.  
  8506. Hal, Thanks very much for your help|
  8507.  
  8508. Christophe JAGUSIAK
  8509.  
  8510. ----- OS2REXX CFORUM appended at 02:47:53 on 92/10/24 GMT (by SAAS1W7 at HONE81)
  8511. Subject: VREXX2: Good Job
  8512. Ref: Append by DPDD at Provident
  8513.  
  8514. Yes, Add VREXX to the BASE OS/2   Very nice addition.
  8515.  
  8516. David DuPre'
  8517. Provident Life and Accident Insurance Co.
  8518.  
  8519. ----- OS2REXX CFORUM appended at 17:59:16 on 92/10/26 GMT (by IL14761 at OS2CUST)
  8520. Subject: Master Environment
  8521.  
  8522. I am trying to find a way to set environment variables in the "Master" environm
  8523. ent.  When a user logs onto the network, I wish to set certain variables for th
  8524. e .batch & .cmd files to use.  Under DOS this was real easy, but can't find any
  8525.  info for doing it under OS/2.  If this is not possible, is there a file like a
  8526. utoexec.bat that runs whenever an OS/2 Fullscreen/Window or desktop object is r
  8527. un?
  8528.  
  8529. Eric Brunsen
  8530. Eastern New Mexico University
  8531.  
  8532. ----- OS2REXX CFORUM appended at 21:33:53 on 92/10/26 GMT (by IL11901 at OS2CUST)
  8533. Subject: Master Environment
  8534. Ref: Append at 17:59:16 on 92/10/26 GMT (by IL14761 at OS2CUST)
  8535.  
  8536.  You can add whatever SET commands you wish to CONFIG.SYS.  However, if
  8537. you need the commands to be set only AFTER logon, specifying a CMD
  8538. file to be run every time is possible by changing the settings of
  8539. the OS/2 Window and OS/2 Fullscreen objects and chaning the parameters
  8540. section.
  8541.  
  8542. Steve Dacek -- Soft & GUI Inc
  8543.  
  8544. ----- OS2REXX CFORUM appended at 15:16:23 on 92/10/27 GMT (by NAAG8T6 at OS2CUST)
  8545. Subject: Please fix VREXX SYS3175
  8546.  
  8547. I have LOTS of trouble testing VREXX due to getting SYS3175, and I get it
  8548. whether on XGA or VGA. Here are my findings today (using XGA desktop):
  8549.  
  8550. 1. If you issue CALL VEXIT twice in a row you get SYS3175.
  8551.  
  8552. 2. Once you've gotten SYS3175, then VINIT() is likely to give ERROR but
  8553. if you reissue it several times you get a RESULT such as v2, v3, etc (where
  8554. the digit keeps increasing). This sort-of allows you to continue w/o reboot.
  8555.  
  8556. There is some fix needed here (I guess to VEXIT) to make it impossible to get
  8557. SYS3175 and the ERROR on VINIT.
  8558.  
  8559. Bruce Ferrero @ Aetna, Middletown, CT
  8560.  
  8561. ----- OS2REXX CFORUM appended at 18:37:27 on 92/10/27 GMT (by MCGUIRE at GDLVM7)
  8562. Subject: SysFileTree not Finding $ Files
  8563. Ref:     Append at 14:59:03 on 92/10/20 GMT (by JERKEWIT at DALVM41B)
  8564.  
  8565. I just checked again, using a directory that only contains a single $* file.
  8566. The DosFindFirst/DosFindNext sequence returned '.', '..', and rc=18.  It
  8567. really does look like a file system problem, particularly since it only
  8568. occurs with HPFS drives.
  8569.  
  8570. Rick McGuire - SAA Rexx Development, Endicott
  8571.  
  8572. ----- OS2REXX CFORUM appended at 15:08:52 on 92/10/29 GMT (by LWILSON at DALVM1)
  8573. Subject: Using SysCreateObject to start a DOS application
  8574.  
  8575. I am trying to use the SyscreateObject call to start WordPerfect in
  8576. a full screen VDM.  I can't figure out how to get it to start in the
  8577. foreground.  It starts fine but I have to use the Task List to get to it.
  8578. Does anyone know how to get this to start in the foreground?
  8579. These are the parameters I am currently using:
  8580.  
  8581. classname='WPProgram'
  8582. title='WordPerfect 5.1'
  8583. location='<WP_NOWHERE>'  /*place in invisible folder*/
  8584. program='EXENAME=W:\WP.EXE;'
  8585. parms='PARAMETERS=/nt=4 /ps=w:\setup;'
  8586. type='PROGTYPE=VDM;'
  8587. max='MAXIMIZED=YES;'
  8588. startup='STARTUPDIR=W:\;'
  8589. settings='SET DOS_FILES=45;'
  8590. open='OPEN=DEFAULT;'
  8591. /*Call the function SysCreateObject using the definitions above*/
  8592. call sysCreateObject classname, title, location,,
  8593. program| |parms| |type| |max| |startup| |settings| |open, 'REPLACE'
  8594.  
  8595. Thanks in advance.
  8596. Lucie Wilson
  8597.  
  8598. ----- OS2REXX CFORUM appended at 20:39:08 on 92/10/29 GMT (by UDSS013 at HONE83)
  8599. Subject: Changing a Files date/time stamp ?
  8600. Ref: Append at 18:11:30 on 92/10/15 GMT (by ROK2027 at HONE82)
  8601.  
  8602. | Is there a function in rexx that will allow a files date and time stamps to be
  8603. | changed...?
  8604.  
  8605. I'm not sure exactly what you mean in the original post. There is a non-REXX
  8606. way to update the time/date stamp on a file to whatever the current date is.
  8607. The utility is usually called 'touch' after the UNIX command.  If you want to
  8608. change the time/date stamp to something other than the current time, there
  8609. isn't way in IBM's OS/2 REXX to do that.  You might want to call Quercus
  8610. Systems at (408) 867-REXX and see if they have a way to do that either in their
  8611. code or an external function package.  Quercus has been developing REXX for
  8612. DOS for quite some time.  They used to be partners with Mansfield Software.
  8613.  
  8614. Back to the original question.  I'm not sure how time/date stamps will implement
  8615. a check.  Just looking at the time stamp would be pretty easy to fool (e.g.
  8616. change the system clock and 'touch' the file).  I would be more inclined to
  8617. calculate something like a CRC (only less obvious) based on the contents of
  8618. the file and place it in the INI.  If the CRC-like key value changed, then
  8619. you know something other than the desired application changed it since presumably
  8620. your application is the only one that knows now to calculate the key.
  8621.  
  8622.