home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 35 Internet / 35-Internet.zip / objst11.zip / README.TXT < prev    next >
Text File  |  1995-07-20  |  9KB  |  182 lines

  1.  
  2. OBJST version 1.10- Start Dos and Windows viewers from Web Explorer!
  3. -------------------------------------------------------------------
  4.  
  5.  
  6. Files included
  7. ---------------
  8.  
  9. viewst.cmd:               REXX template for starting the viewer.
  10. objst.exe:                program which starts the viewer
  11. objst.c:                  code for objst.exe
  12. readme.txt:               this file; direction for use
  13. objst.txt:                Archive upload file
  14. proghand.exe:             small program which creates a program object with 
  15.                           known ID
  16. proghand.c:               source for proghand.exe
  17.  
  18.  
  19.  
  20. Description and Instructions
  21. ----------------------------
  22.  
  23.    This program, objst.exe, can be used to start Windows and Dos based
  24. viewers easily from Web Explorer.  It can also be used to start OS/2
  25. viewers.  There are 2 problems it solves, the first is that WebEx won't
  26. easily pass any command line arguments to the program, besides the filename.
  27. You can use this method of starting viewers to do so.  Secondly, for
  28. Windows and Dos programs, there hasn't been a way (AFAIK) to define
  29. any DOS Settings, for example, how much memory, to start the Windows
  30. program seamlessly, to start it in Enhanced Mode, etc.  To tackle these
  31. problems, objst.exe will in fact open a program object you have created
  32. on your desktop.
  33.  
  34. 1) You should put objst.exe somewhere on your path (though not necessary,
  35.    just change the REXX file to locate it. The REXX file must be changed
  36.    anyway, to put in the proper object handle).
  37.  
  38. 2) For each viewer you plan on starting this way, make a program object.
  39.    If you already have a program object for a viewer, great, but you 
  40.    should make a copy of it.  The Parameters field on the first page
  41.    will be overwritten (and not erased), so it shouldn't be the same
  42.    object you use for general purposes.  Make sure the Working Directoy
  43.    field is empty.  don't use a shadow of an existing viewer either (and
  44.    don't copy a shadow, this just makes another shadow).  You will need
  45.    to know the object handle of this program object.  Use the included
  46.    proghand.exe to create this object.  It is placed on the desktop, and
  47.    the program reports back its object handle.  Any parameters passed are used
  48.    for the program object's title.  If no arguments, a default title is
  49.    given.  This program object should be set to "Create Another" on the
  50.    window page of the settings notebook, and you will probably also want
  51.    to _NOT_ use a separate session (for Windows viewers).
  52.  
  53. 3) For each viewer you will need to make a REXX .cmd file.  I have included
  54.    one, which you should make copies of and modify.  The REXX is documented,
  55.    please read it.  WebEx will call this REXX .cmd file, and pass it the 
  56.    filename for the viewer to view.  Basically, the REXX does the following:
  57.  
  58.    a) Copies the file passed to it (???????n.???) to ???????l.??? where n
  59.       is a number from 0 to 9, and l is a letter from a to j.  Why does it 
  60.       do this?  Well, when the REXX script ends, WebEx will delete the .tmp 
  61.       file, and it will be gone before the viewer can view it.  So, we must 
  62.       copy it before WebEx deletes it.  However, this will litter your temp 
  63.       directory with these copied files, which must manually be deleted.  
  64.       Make a .cmd file wich does something like "del %temp%\*", and make a 
  65.       program object which calls it.  Then you can put it in your startup 
  66.       folder to clean out your temp directory on bootup.
  67.  
  68.    b) It then calls objst.exe.  The first argument passed is the "object
  69.       handle" (found by creating program object with proghand.exe) of the 
  70.       program object to start.  After this, any command line arguments, 
  71.       and the filename to view, can be passed, in any order.  My REXX 
  72.       script (viewst.cmd) documents this.  objst.exe is the executable 
  73.       which tells OS/2 to open up the program object.
  74.  
  75. 4) Ok, so the REXX script is set up to open the program object.  You could
  76.    try it out now from the command line if you'd like.  You should probably
  77.    put it somewhere on your path, but again I don't think this is necessary,
  78.    you can specify the full path in the Web Explorer.
  79.  
  80. 5) Start Web Explorer.  Go to configure the viewers.  Have it call the
  81.    REXX file you just created.  If you need to edit your extmap.ext and
  82.    mailcap.cap files for this viewer, just call the REXX file followed by %s.
  83.    Volia!  You should now be able to use the Dos or Windows based viewer.
  84.  
  85.  
  86. More on using with Web Explorer
  87. -------------------------------
  88. I hope this isn't confusing.  Here's a more specific example.  Say you want
  89. to view Quicktime movies.  You have Quicktime for Windows 2.0 installed,
  90. and can use the Windows Media Player applet to watch them.  But, you want
  91. Web Explorer to load them up also.  First, you'd go make a new program
  92. object for the Windows Media Player, setting the Dos Settings as necessary.
  93. Then you'd copy the sample REXX file to, say, qtw.cmd.  Make this object with
  94. proghand.exe, so you can get the object handle.  Edit qtw.cmd, and put the 
  95. correct object handle on the last line.  Finally, in Web Explorer, configure 
  96. the Quicktime viewer to call qtw.cmd.  Now, when WebEx gets a quicktime movie,
  97. it will load it into the Windows media player applet.  You can give the
  98. media player as much memory as you'd like, make it seamless, separate
  99. session, or fullscreen as you please.  You have the full power of OS/2's
  100. program objects at your disposal to define exactly how you want the viewer
  101. to run.
  102.  
  103. Another example would be the Real Audio player.  Download it and install it
  104. (http://www.realaudio.com).  Then, use proghand.exe to create a program
  105. object.  Edit it to give it whatever settings you want.  You should use
  106. "Create Another" and "Same Session".  Make it run in 386 Enhanced mode, and
  107. give it a good amount of DPMI memory.  "Create Another" and "Same Session"
  108. will let RealAudio use an already loaded copy of the player, if you've
  109. already been listening to music.  The program object should call pnclient.exe.
  110. Now, copy the sample REXX script, and replace the object handle with the
  111. one for your RealAudio object, which was reported by proghand.exe.  Now,
  112. we need to add a MIME type for Web Explorer to support Realaudio.  First,
  113. edit \tcpip\etc\explore.ini.  Find the advanced section.  It will look
  114. like this:
  115.  
  116. [advanced]
  117. ; advanced user settings - edit with care!
  118. ;
  119. ; mailcap= specifies full path to user mailcap file
  120. ; format is:  mime/type; program_name params %s
  121. ; example:    image/jpeg; jview -r %s
  122. ; no wildcards allowed, no piping, no unix commands
  123. mailcap=
  124. ; extmap= specifies full path to user extension map file
  125. ; format is:  mime/type     extension_list
  126. ; example:    image/jpeg    jpg jpeg jpe
  127. extmap=
  128.  
  129. Place pathnames to mailcap.cap and extmap.ext files on the above two lines.
  130. Probably want \tcpip\etc\mailcap.cap and \tcpip\etc\extmap.ext.  Make sure
  131. you aren't running any copies of Web Explorer when running this.
  132.  
  133. Now, create mailcap.cap and put this line in it:
  134.      audio/x-pn-realaudio;   raclient.cmd %s
  135. Where raclient.cmd is the name of the REXX file used to call the RealAudio
  136. program object.
  137.  
  138. Finally, edit the extmap.ext and put this file in it:
  139.      audio/x-pn-realaudio    ra ram
  140.  
  141. This procedure is documented in the Web Explorer help files.
  142.  
  143. You should now be able to click on RealAudio links, have Web Explorer load
  144. up the RealAudio player, and play the music.
  145.  
  146.  
  147. Instructions on using proghand.exe
  148. ----------------------------------
  149. All this program does is create a standard OS/2 program object on the desktop.
  150. You can specify a title (including spaces) on the command line for the object.
  151. All setting must be configured once it is created.  proghand.exe will report
  152. back the object handle of this object, which must be passed to objst.exe.
  153.  
  154.  
  155. Disclaimer
  156. ----------
  157. Use at your own risk.
  158.  
  159.  
  160. You are free to look at the code, see how it works, and use it for whatever.
  161. It is actually quite trivial.  If you make any changes, email them to me,
  162. and I will see about including them in an updated version.  Feel free to
  163. email if you have any ideas for enhancements, or a bug report.  You are free
  164. to redistribute this archive, but it must remain unchanged.  This program
  165. is freeware.
  166.  
  167.  
  168. Brian Landy
  169. blandy@ucsd.edu
  170.  
  171.  
  172. copy of FILE_ID.DIZ
  173. -------------------
  174. (v1.10) Objst: Start WPS program objects
  175. from the command line.  Primarily
  176. useful for starting Dos and Windows
  177. viewers from IBM's Web Explorer.  Can
  178. also be used to pass programs arguments
  179. other than filename from Web Explorer.
  180. Archive contains instructions for setup
  181. with Web Explorer.
  182.