home *** CD-ROM | disk | FTP | other *** search
/ DTP Toolbox / DTPToolbox.iso / propage4.0 / arexx / readini.rexx < prev    next >
Encoding:
OS/2 REXX Batch file  |  1992-06-17  |  369 b   |  24 lines

  1. /*
  2.     This genie parses the PPage.ini file for a specific object type
  3. */
  4.  
  5. parse arg type, filename
  6.  
  7. if filename = '' then filename = "s:ppage.ini"
  8.  
  9. type = upper(type)
  10.  
  11. if ~open(file, filename, r) then return("")
  12. rstring = ''
  13.  
  14. do while ~eof(file)
  15.  
  16.     line = upper(readln(file))
  17.     if word(line, 1) = type then rstring = subword(line, 2)
  18. end
  19.  
  20. call close(file)
  21. return rstring
  22.  
  23.  
  24.