home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 11 Util / 11-Util.zip / resex111.zip / RESEX.TXT < prev   
Text File  |  2002-04-24  |  7KB  |  188 lines

  1. USAGE: RESEX
  2.         -H<used to display RESEX help>
  3.         -F<input .EXE or .DLL>
  4.         -O<path resources to be extracted to>
  5.         -T<resource type to be extracted or deleted>
  6.         -X<file extention to be used>
  7.         -I<extract icons only in icon format>
  8.         -B<extract bitmaps only in bitmap format>
  9.         -Q<extract data (0x09) resources only with no header>
  10.         -U<.RES file with replacements>
  11.         -D<resource names to be removed>
  12.         -A<resource name,resource data>
  13.         -Z<used to preserve original file date/time stamp>
  14.  
  15. Resource Extractor for OS/2
  16. RESEX utility enables the user to (1) extract Icons,
  17. Dialogs, Menus and other resources from .EXEs or
  18. .DLLs to reuse them in other applications, (2) add,
  19. modify or replace Dialogs, Icons, Menus etc. in
  20. existing .EXEs or .DLLs ,(3) remove arbitrary
  21. resources from .EXE or .DLL and, finally, (4) add
  22. arbitrary data string to .EXE or .DLL to be able to
  23. retrieve  it later as RT_RCDATA resource
  24. RESEX.EXE processes 32-bit (LX) .EXE or .DLL files
  25. and does the following things:
  26.  
  27. 1. Displays Resource Table contents showing each
  28. resource type, name, size, file offset and flag bits for
  29. the object that contains resource. Parameter -F
  30. describes file to be processed. The following is an
  31. example:
  32.  
  33.         RESEX -Fabc.exe
  34.  
  35. 2. Extracts resources. Extracted resources will be
  36. stored as Rnnnnnn.hhh in a directory given by
  37. parameter -O. Here, nnnnnn is a resource name, hhh
  38. is a resource type (hexadecimal constant). For
  39. example, Dialog 100 will be stored as R100.4. If
  40. parameter -T is used, it defines resource type to be
  41. extracted. In this case, you may use parameter -X to
  42. define file extension. If you want to extract Icons or
  43. Bitmaps  and create .ICO or .BMP files ready to be
  44. processed by ICONEDIT, use parameters -I or -B.
  45. To extract RT_RCDATA resource without resource
  46. header, use parameter -Q. The following are
  47. examples:
  48.  
  49.         RESEX -Fabc.exe -Oc:\res
  50.         Will extract all resources from abc.exe and
  51.         will save them in c:\res directory
  52.  
  53.         RESEX -Fabc.dll -Oc:\res -T4 -Xres
  54.         Will extract all DIALOG resources (type=4)
  55.         from abc.dll and will save them in c:\res
  56.         directory. Files will have .RES extensions.
  57.         Later you can use DLGEDIT utility to
  58.         modify them and create new .RES and .DLG
  59.         files. At this point you can easily reuse
  60.         them in you application.
  61.  
  62.         RESEX -Fabc.dll -Oc:\icons -I
  63.         Will extract all Icons from abc.dll and will
  64.         save them in c:\icons with extension .ICO.
  65.         Note that if you use
  66.                 RESEX -Fabc.dll -Oc:\icons -T1 -Xico ,
  67.         that will also extract all Icons but results will
  68.         include 12-byte resource prefix that will
  69.         precede icon bytes.
  70.  
  71. 3. Replaces resources in the target .EXE or .DLL.
  72. Replacements must be in the resource file given by
  73. parameter -U.  If you want to preserve target file's
  74. day/time stamp, use parameter -Z. Examples:
  75.  
  76.         If you want to modify a dialog in abc.exe:
  77.         (1) extract all Dialogs by using
  78.                 RESEX -Fabc.exe -Oc:\res -T4 -Xres
  79.  
  80.         (2) locate your Dialog by name (the file name
  81.         will be Rnnnnnn.RES),modify it using
  82.         DLGEDIT and save it (for example, in abc.res)
  83.  
  84.         (3) execute
  85.                 RESEX -Fabc.exe -Uabc.res -Z
  86.  
  87.         To modify an icon in abc.exe:
  88.  
  89.         (1) extract all Icons by using
  90.                 RESEX -Fabc.exe -Oc:\icons -I
  91.  
  92.         (2) find your  Icon  by name and  modify it by
  93.         using ICONEDIT
  94.  
  95.         (3)  create .RC file with the following
  96.         contents:
  97.  
  98.                 ICON name-id  icon-file-name
  99.  
  100.         then compile it creating .RES file (say,
  101.         abc.RES) ;
  102.  
  103.         (4) and, finally, run
  104.                 RESEX -Fabc.exe -Uc:\res\abc.res -Z
  105.  
  106.  
  107.         Note that any number of resources can
  108.         appear one after another in replacement file.
  109.         To concatenate resources, use COPY /b
  110.  
  111.  
  112. 4. Removes resources from the target .EXE or .DLL.
  113. In this case, parameter -D describes resource names
  114. to be removed  (comma separated list),  parameter -T
  115. describes resource type. Note that if -D list is empty,
  116. all resources will be removed. The following are
  117. examples:
  118.  
  119.         RESEX -Fabc.dll -D12,14,245  -T9 -Z
  120.         Will remove data resources (type = 9) 12, 14
  121.         and 245 from the target file abc.exe.
  122.  
  123.         RESEX -Fabc.exe -D -T9
  124.         Will remove all data resources from the target
  125.         file abc.exe
  126.  
  127. 5. Adds arbitrary data string to the target .EXE or
  128. .DLL files as a data resource. Use parameter -A that
  129. has the following format:
  130.  
  131.         -A<name>,<data>
  132.  
  133. If <data> starts with @ symbol, the following
  134. characters in <data> describe path name of the file containing
  135. the data to be added. The following are examples:
  136.  
  137.         RESEX -Fabc.exe -A100,NevaObjectTech
  138.         Will add string "NevaObjectTech" to
  139.         abc.exe as a data resource number 100. Note
  140.         that if you want to use space characters
  141.         inside your string, use double quotes:
  142.  
  143.         RESEX -Fabc.exe "-A100,Neva Object Tech"
  144.  
  145.         RESEX -fabc.exe -A1000,@c:\config.sys
  146.         Will add contents of c:\config.sys to
  147.         abc.exe as a data resource 1000.
  148.  
  149. Note that if resource already exist in the target file,
  150. it will be replaced.
  151.  
  152. To extract data, you may use -Q option that extracts
  153. data resources without resource header:
  154.  
  155.         RESEX -fabc.exe -O. -Q
  156.         Will extract "Neva..." string to R0100.DAT
  157.         file and  former config.sys to R1000.DAT file
  158.         in the current  directory.
  159.  
  160. You can extract data during execution of abc.exe by
  161. using DosGetResource API. This functionality is very
  162. helpful, for example, to bind variable data (password,
  163. configuration data, etc.) to .EXE or .DLL and to retrieve
  164. this information later in a run time. BTW, RESEX uses that
  165. to store help information. To extract this text:
  166.  
  167. 1. copy RESEX.EXE to TEMP
  168. 2. execute RESEX -fTEMP -O. -Q
  169. 3. Finally, you will find this text in R1000.DAT
  170.  
  171. DISCLAIMER:
  172.  
  173. This product is supplied "AS IS", and without any
  174. warranties. Neva Object Technology, Inc. accepts no
  175. responsibility for any loss or damage; whether
  176. physical, financial, emotional, social, mental, marital,
  177. or otherwise that may result from the use of this
  178. product
  179.  
  180. If you have any comments or suggestions please feel
  181. free to contact us at
  182.  
  183. Neva Object Technology, Inc
  184. 1409 Strattford Street, Suite E
  185. Brea California 92621 USA
  186. Phone: (714) 671-4107
  187. Fax: (714) 256-1916
  188.