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

Re: [Clip] Edit ini

Expand Messages
  • Larry Hamilton
    As I understand it, it only reads the ini when the program is first started. I am not aware of a way to make NoteTab read the ini without a re-start. I believe
    Message 1 of 4 , Feb 8, 2003
      As I understand it, it only reads the ini when the program is first started.
      I am not aware of a way to make NoteTab read the ini without a re-start.

      I believe some have gotten around this with clips that start a new instance
      of NoteTab and close the current instance.

      Larry

      David wrote:
      > Hi
      > If I make a mistake in the quicklist say d:\html\midi\*.clb or wish to
      > remove entries from the quicklist the only way is to edit the ini , the
      > only problem is the ini does not update tilll you close nts I have tried
      > the clips below partial success but I still can not udate the [directory
      > list] in the ini ,What am I missing ???
    • Alan C.
      Hi Larry, Dave, ... I think ^!ProgIniLoad is supposed to force a current read of the ini except for the autoload section. help help on clip programming
      Message 2 of 4 , Feb 8, 2003
        Hi Larry, Dave,

        >As I understand it, it only reads the ini when the program is first started.
        >I am not aware of a way to make NoteTab read the ini without a re-start.

        I think ^!ProgIniLoad is supposed to force a current read of the ini except for the autoload section. help > help on clip programming > index tab > ^!ProgIniLoad

        But I can't get it to work with DirectoryList section of ini. Just a week or two ago, Sheri had it working very nicely with the SearchFiles:ReplaceList_1 section or portion of the ini

        ^!SetIniFile
        ^!ProgIniSave
        ^!SaveValue DirectoryList:Specs_3=D:\files\ntbdocs\*.txt;*.otl
        ^!ProgIniLoad

        (unless DirectoryList is excepted perhaps xtra colon in filepath won't accept or something) That above code should accordingly change and save my Specs_3 line that's immediately below this paragraph and then force a read of the new disk value. But it's not doing it.

        [DirectoryList]
        SpecsCount=4
        Specs_1="d:\programs\notetab pro\documents\*.txt"
        Specs_2="files_of_mine"
        Specs_3="d:\files\*.*"
        Specs_4="d:\files\ntbdocs\*.*"

        BTW on my Win 2k machine, Specs_2="files_of_mine" shows all text (*.txt) files that are on my desktop. Surprise to me how about that one! Did I discover a hidden Easter Egg so to speak?

        --
        Later. Alan.
      • hsavage
        ... Larry, David and Alan, It s been a long time since I ve used Notetab Standard, or, in my case, SuperNoteTab. That was way back when I wasn t real sure
        Message 3 of 4 , Feb 9, 2003
          Larry Hamilton wrote:

          >As I understand it, it only reads the ini when the program is first started.
          >I am not aware of a way to make NoteTab read the ini without a re-start.
          >
          >I believe some have gotten around this with clips that start a new instance
          >of NoteTab and close the current instance.
          >
          >Larry
          >
          >David wrote:
          >
          >
          >>Hi
          >>If I make a mistake in the quicklist say d:\html\midi\*.clb or wish to
          >>remove entries from the quicklist the only way is to edit the ini , the
          >>only problem is the ini does not update till you close nts I have tried
          >>the clips below partial success but I still can not udate the [directory
          >>list] in the ini ,What am I missing ???
          >>
          >>
          Larry, David and Alan,

          It's been a long time since I've used Notetab Standard, or, in my case,
          SuperNoteTab. That was way back when I wasn't real sure what clips or
          clip language was about.

          Does Standard read and write to inifiles differently than NTPro. If
          not, you can write changes to the notepro/notetab ini file and then see
          them in the file when you load it, or, reload it, whichever the case.

          The clip below demonstrates writing to, and reading, the ini file
          without the necessity of closing NoteTab.

          My comments may not be entirely accurate but after many attempts these
          actions seem to function as I comment.

          I usually have UAS with a clipcode shorthand library active. I did
          notice that on one occasion I had to toggle UAS off, then, back on for
          clip to work correctly.

          Other than that, and it may have been a coincidence, there was no
          problem with the clip function.

          The line that sets 2 variables, a single line, is, I think, the only
          line long enough to give a problem with email wrapping, check others to
          be sure.

          hrs
          ----------------------

          H="WRITE TO NOTEPRO/NOTETAB INIFILE"
          ;_Modified~Updated~Created_2/9/03_8:51:37a_hsavage@...
          ^!ClearVariables
          ;
          ; writes current state of current inifile to disk
          ^!ProgIniSave
          ;
          ; ensures the default ini is selected and active
          ; not needed unless another inifile has been active in same clip
          ^!SetIniFile
          ;
          ; open inifile to visually select item number
          ^!Set %whichini%=^?[WHICH INIFILE==_NOTEPRO|NOTETAB].ini
          ^!Open ^$GetAppPath$^%whichini%
          ^!Find "[DirectoryList]" S
          ^!SetView ^$GetRow$:1
          ;
          ; sequence of commands between dashed lines is critical
          ;-------------------------
          ; enter item number and new item data
          ; ** long line, check for email wrapping **
          ^!Set %item#%=^?{ENTER DIRECTORYLIST ITEM NUMBER=2};
          %itemdata%=^?{DIRECTORYLIST DATA-LEAVE BLANK IF DELETING DATA=}
          ;
          ; writes data to NoteTab ram or deletes if itemdata is blank
          ^!SaveValue DirectoryList:Specs_^%item#%=^%empty%^%itemdata%
          ;
          ; inifile plus new data in ram is read into Notetab
          ^!ProgIniLoad
          ;
          ; inifile with new data in Notetab is written to disk
          ^!ProgIniSave
          ;^!Delay 2
          ;-------------------------
          ; inifile is reloaded so write can be verified
          ^!Open ^$GetAppPath$^%whichini%
          ^!Find "[DirectoryList]" S
          ^!SetView ^$GetRow$:1
        • Larry Hamilton
          Well, that shows how much I use this option. ;-) Larry
          Message 4 of 4 , Feb 9, 2003
            Well, that shows how much I use this option. ;-)

            Larry

            hsavage wrote:
            > The clip below demonstrates writing to, and reading, the ini file
            > without the necessity of closing NoteTab.
            >
            > ; inifile plus new data in ram is read into Notetab
            > ^!ProgIniLoad
          Your message has been successfully submitted and would be delivered to recipients shortly.