Loading ...
Sorry, an error occurred while loading the content.

Rexx function library for Windows style INI files

Expand Messages
  • Herwig Bauernfeind
    I remember there was a REXX function library that provided easy access to Windows style .INI files (those text files like WIN.INI or SYSTEM.INI), but I can t
    Message 1 of 12 , Jan 9, 2002
    View Source
    • 0 Attachment
      I remember there was a REXX function library that provided
      easy access to Windows style .INI files (those text files like
      WIN.INI or SYSTEM.INI), but I can't remember it's name
      and I cannot find it...

      Could anybody help me?

      Herwig

      --
      +---------------------------------------------------
      | Mag. Herwig Bauernfeind - Dfb. J.Bfd. - Accountant
      | Martin-Luther-Str.12, A-9300 St.Veit/Glan, Austria
      | Telefon: ++43 4212 2028 Telefax: ++43 4212 2028 76
      | herwig.bauernfeind@... - Fidonet: 2:313/41.5
    • Eric Lavoie
      ... RxIni i think, look at hobbes.
      Message 2 of 12 , Jan 10, 2002
      View Source
      • 0 Attachment
        On Thu, 10 Jan 2002 08:09:21 +0100, Herwig Bauernfeind wrote:

        >I remember there was a REXX function library that provided
        >easy access to Windows style .INI files (those text files like
        >WIN.INI or SYSTEM.INI), but I can't remember it's name
        >and I cannot find it...
        >
        >Could anybody help me?

        RxIni i think, look at hobbes.
      • Herwig Bauernfeind
        ... Found it, got it, thanks a lot or maybe mercí beaucoup? herwig -- +---------------------------------------------------
        Message 3 of 12 , Jan 10, 2002
        View Source
        • 0 Attachment
          Eric Lavoie schrieb:

          > On Thu, 10 Jan 2002 08:09:21 +0100, Herwig Bauernfeind wrote:
          >
          > >I remember there was a REXX function library that provided
          > >easy access to Windows style .INI files (those text files like
          > >WIN.INI or SYSTEM.INI), but I can't remember it's name
          > >and I cannot find it...
          > >
          > >Could anybody help me?
          >
          > RxIni i think, look at hobbes.

          Found it, got it, thanks a lot or maybe mercí beaucoup?

          herwig

          --
          +---------------------------------------------------
          | Mag. Herwig Bauernfeind - Dfb. J.Bfd. - Accountant
          | Martin-Luther-Str.12, A-9300 St.Veit/Glan, Austria
          | Telefon: ++43 4212 2028 Telefax: ++43 4212 2028 76
          | herwig.bauernfeind@... - Fidonet: 2:313/41.5
        • Eric Lavoie
          ... Bienvenue :-) do not try these on ibmlan.ini and protocol.ini it will crash, they are only for MS style ini files. If you get in contact with the author
          Message 4 of 12 , Jan 10, 2002
          View Source
          • 0 Attachment
            On Thu, 10 Jan 2002 17:48:22 +0100, Herwig Bauernfeind wrote:

            >Eric Lavoie schrieb:
            >
            >> On Thu, 10 Jan 2002 08:09:21 +0100, Herwig Bauernfeind wrote:
            >>
            >> >I remember there was a REXX function library that provided
            >> >easy access to Windows style .INI files (those text files like
            >> >WIN.INI or SYSTEM.INI), but I can't remember it's name
            >> >and I cannot find it...
            >> >
            >> >Could anybody help me?
            >>
            >> RxIni i think, look at hobbes.
            >
            >Found it, got it, thanks a lot or maybe mercí beaucoup?

            Bienvenue :-) do not try these on ibmlan.ini and protocol.ini it will crash, they are only for MS style ini files.
            If you get in contact with the author please tell me, i would like to get source to allow reading protocol.ini
          • Herwig Bauernfeind
            ... Thanks for the hint. My intention is a nice front end for Odin.INI, which is in MS style. ... Okay. Herwig --
            Message 5 of 12 , Jan 10, 2002
            View Source
            • 0 Attachment
              Eric Lavoie schrieb:

              > do not try these on ibmlan.ini and protocol.ini it will crash, they are only for MS style ini files.

              Thanks for the hint. My intention is a nice front end for Odin.INI, which is in MS style.

              > If you get in contact with the author please tell me, i would like to get source to allow reading protocol.ini

              Okay.

              Herwig

              --
              +---------------------------------------------------
              | Mag. Herwig Bauernfeind - Dfb. J.Bfd. - Accountant
              | Martin-Luther-Str.12, A-9300 St.Veit/Glan, Austria
              | Telefon: ++43 4212 2028 Telefax: ++43 4212 2028 76
              | herwig.bauernfeind@... - Fidonet: 2:313/41.5
            • Freiheit
              I believe you are looking for FastINI. I don t know exactly where to download it, but I believe it comes with Goran Ivankovic s utilities at:
              Message 6 of 12 , Jan 10, 2002
              View Source
              • 0 Attachment
                I believe you are looking for FastINI. I don't know exactly where to
                download it, but I believe it comes with Goran Ivankovic's utilities
                at:

                http://www.os2world.com/goran/


                >I remember there was a REXX function library that provided
                >easy access to Windows style .INI files (those text files like
                >WIN.INI or SYSTEM.INI), but I can't remember it's name
                >and I cannot find it...
                >
                >Could anybody help me?
                >
                >Herwig


                ---------------
                Don "Freiheit" Eitner

                * Developer of The 13th Floor website
                (http://freiheit.syntheticdimension.net)
                * Official redhead admirer
                * Using OS/2 because I want to, not because I "have to".
              • a_schnellb
                ... fastini.dll is from Dennis Bareis. It speeds up OS/2 (not win) style ini access by a factor of 100 in most cases.
                Message 7 of 12 , Jan 12, 2002
                View Source
                • 0 Attachment
                  Freiheit wrote:

                  > I believe you are looking for FastINI. I don't know exactly
                  > where to download it,

                  fastini.dll is from Dennis Bareis. It speeds up OS/2 (not win)
                  style ini access by a factor of 100 in most cases.
                  http://www.labyrinth.net.au/~dbareis/index.htm

                  > but I believe it comes with Goran Ivankovic's utilities at:

                  Goran has developed 'Ini Tools' and 'Ini Editor'. I think he
                  has functions to convert one ini format into the other.

                  So a possibility could be: Do everything with OS/2 ini functions
                  and convert it afterwards to win ini style.

                  BTW, I'm doing it here the standard way: Rewrite the hole ini
                  after collecting all settings. Why use a special dll? Ok,
                  parsing the ini could be easier by an additional function.
                  But parsing with REXX is so versatile, that I don't feel a
                  need for it.

                  If you need an example how to read and write win ini files,
                  I'll post it.

                  --
                  Andreas Schnellbacher
                • Herwig Bauernfeind
                  ... Don t like to invent the wheel twice? ... If the the function library was well written it would be quite handy However, I am producing lots of crashes
                  Message 8 of 12 , Jan 13, 2002
                  View Source
                  • 0 Attachment
                    a_schnellb schrieb:

                    > So a possibility could be: Do everything with OS/2 ini functions
                    > and convert it afterwards to win ini style.
                    >
                    > BTW, I'm doing it here the standard way: Rewrite the hole ini
                    > after collecting all settings. Why use a special dll?

                    Don't like to invent the wheel twice?

                    > Ok,parsing the ini could be easier by an additional function.
                    > But parsing with REXX is so versatile, that I don't feel a
                    > need for it.

                    If the the function library was well written it would be quite handy
                    However, I am producing lots of crashes (SYS3175) because
                    there is almost no error checking implemented -- I would have to
                    do this myself, so I think I also will do it the usual ways...

                    > If you need an example how to read and write win ini files,
                    > I'll post it.

                    Please! As I said, no need to reinvent the wheel...

                    Herwig


                    --
                    +---------------------------------------------------
                    | Mag. Herwig Bauernfeind - Dfb. J.Bfd. - Accountant
                    | Martin-Luther-Str.12, A-9300 St.Veit/Glan, Austria
                    | Telefon: ++43 4212 2028 Telefax: ++43 4212 2028 76
                    | herwig.bauernfeind@... - Fidonet: 2:313/41.5
                  • Andreas Schnellbacher
                    ... I ve taken the first example from one of my apps, where I m able to switch between OS/2 and win style inis. For your purpose you have to change some
                    Message 9 of 12 , Jan 13, 2002
                    View Source
                    • 0 Attachment
                      Herwig Bauernfeind <herwig.bauernfeind@a...> wrote:

                      > a_schnellb schrieb:
                      >
                      > > If you need an example how to read and write win ini files,
                      > > I'll post it.
                      >
                      > Please! As I said, no need to reinvent the wheel...

                      ---- test-ini.cmd ----
                      I've taken the first example from one of my apps, where I'm able
                      to switch between OS/2 and win style inis.

                      For your purpose you have to change some functions:
                      Instead of just parsing, set for every 'IniLine.l' a var
                      'OutLine.l'. Compare current Application, KeyWord and
                      KeyValue with the strings you want to edit.

                      * If Application and Keyword is found, then edit current line.
                      * If only Application was found and current line is a new
                      Application definition, then insert your new
                      Keyword' = 'KeyValue line before.
                      * If Application and KeyWord are not found, but there are
                      some keys remaining, then append them with a '['Application']'
                      line before.

                      For getting the setup from an ini the comments and empty lines
                      are ignored. Here you have to let it unchanged in the OutFile.

                      ---- edit-ini.cmd----
                      Ok, I've done some of it myself. REXX coding means fun!
                      Hope you can use it anyhow.

                      --
                      Andreas Schnellbacher
                    • Herwig Bauernfeind
                      Hi Andreas, ... Thanks, I ll look at it later. Herwig -- +---------------------------------------------------
                      Message 10 of 12 , Jan 14, 2002
                      View Source
                      • 0 Attachment
                        Hi Andreas,


                        > > > If you need an example how to read and write win ini files,
                        > > > I'll post it.
                        > >
                        > > Please! As I said, no need to reinvent the wheel...
                        >
                        > ---- test-ini.cmd ----

                        Thanks, I 'll look at it later.

                        Herwig
                        --
                        +---------------------------------------------------
                        | Mag. Herwig Bauernfeind - Dfb. J.Bfd. - Accountant
                        | Martin-Luther-Str.12, A-9300 St.Veit/Glan, Austria
                        | Telefon: ++43 4212 2028 Telefax: ++43 4212 2028 76
                        | herwig.bauernfeind@... - Fidonet: 2:313/41.5
                      • a_schnellb
                        ... wrote: [test-ini.cmd] select would only give a better looking structure. [edit-ini.cmd] In function EditIniFile you better
                        Message 11 of 12 , Jan 18, 2002
                        View Source
                        • 0 Attachment
                          --- In GuiObjectRexx@y..., Andreas Schnellbacher
                          <Andreas.Schnellbacher@w...> wrote:

                          [test-ini.cmd]
                          'select' would only give a better looking structure.

                          [edit-ini.cmd]
                          In function 'EditIniFile' you better use 'select' after the
                          'do l =' loop.

                          Remember there exist some tools to edit strings or files.
                          The problem is, that they should handle the syntax of an ini
                          file while processing (i.e. comments). But it's such an
                          easy syntax, that you only need a regexp search & replace.
                          How about trying the REXX DLL from Dennis Bareis?

                          Here are some (maybe) intersting links:

                          http://hobbes.nmsu.edu/pub/os2/dev/rexx/rxmulch2.zip
                          o rxmulch.cmd by Rony Flatcher

                          ftp://ftp.leo.org/pub/comp/os/os2/leo/rexx/cube.zip
                          o cube.cmd by Didier Lafon

                          http://www.labyrinth.net.au/~dbareis/freeos2.htm
                          o RxRegExp.dll by Dennis Bareis
                          o textedit.cmd by Dennis Bareis
                          o Some ini dealing apps, but only for processing os2 ini files.

                          Or (after finding a string) just use a function with the syntax
                          of 'translate':

                          replacestring: procedure
                          source_str = arg(1)
                          out_str = arg(2)
                          in_str = arg(3)
                          do forever
                          p = pos( in_str, source_str )
                          if not p then leave
                          source_str = insertstr( out_str,,
                          delstr( source_str, p, length(in_str) ),,
                          p - 1 )
                          end /* do */
                          return source_str

                          --
                          Andreas Schnellbacher
                        • Dr. Martin R. Hadam
                          ... RXMulch is excellent - but unfortunately, huge. Even after stripping out the help screen it s still ca 30kB. It d be godsend if a decent programmer created
                          Message 12 of 12 , Jan 18, 2002
                          View Source
                          • 0 Attachment
                            On Fri, 18 Jan 2002 17:27:44 -0000, a_schnellb wrote:

                            >Remember there exist some tools to edit strings or files.
                            >The problem is, that they should handle the syntax of an ini
                            >file while processing (i.e. comments). But it's such an
                            >easy syntax, that you only need a regexp search & replace.
                            >How about trying the REXX DLL from Dennis Bareis?
                            >Here are some (maybe) intersting links:
                            >http://hobbes.nmsu.edu/pub/os2/dev/rexx/rxmulch2.zip
                            > o rxmulch.cmd by Rony Flatcher

                            RXMulch is excellent - but unfortunately, huge. Even after stripping
                            out the help screen it's still ca 30kB. It'd be godsend if a decent
                            programmer created / added a decent search/replace function to one of
                            the (existing) REXX dlls. It's one of the most needed functions when
                            doing string handling - yet unavailable for classic rexx. Nowhere. It's
                            no less than appalling. Unfortunately, using ORexx [i.e. changestr()]
                            with "classic" scripts it not recommended either if you care about
                            performance (like in CGIs).

                            Martin

                            Martin R. Hadam
                            Kinderklinik - Medizinische Hochschule
                            D-30623 Hannover
                            Germany
                            Email: Hadam.Martin@...
                          Your message has been successfully submitted and would be delivered to recipients shortly.