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

[Clip] Re: opening a directory structure

Expand Messages
  • Jody
    Hi Rob, ... There were some things missing and the lines were wrapped. I also took out the binary files. It was originally taken from a file maintenance type
    Message 1 of 2 , Sep 3, 1999
    • 0 Attachment
      Hi Rob,

      > Could someone help me to get this working? I think it was Jody
      > who originaly posted this clip. It is supose to open all files
      > within a directory structure.

      There were some things missing and the lines were wrapped. I
      also took out the binary files. It was originally taken from a
      file maintenance type Clip or WinZip Clip which was the reason
      for having the binary file types listed in it. I also added two
      other methods for you to try out - at no extra chrage. <g>

      <--- Copy below this line --->
      H=Open Full Dirctories
      ; 09/03/1999, Ntb-Clips@..., jody
      ; Opens all files in a directory

      ^!SetWizardLabel Opens all files of type(s) entered
      ; long line till blank line
      ^!Set %Path%=^?{(T=D)Directory path=E:\NTP\Documents\test\}; %Ext%=^?{(H=10)File Types, wildcards OK: *.txt or *.*htm*;*.txt=_All Files^=*.*|Html Only^=*.*htm*|Text Only^=*.txt|Html & Text^=*.*htm*;*.txt|Outline^=*.otl|Clipbook Library^=*.clb|Ini^=*.ini}

      ^!Set %Full%=^$GetFileFirst(^%Path%;"^%Ext%")$

      :Loop
      ^!IfTrue ^$IsEmpty(^%Full%)$ End
      ^!Open ^%Full%
      ^!Set %Full%=^$GetFileNext$
      ^!GoTo Loop


      H=Open Dialog Multi-Files
      ; 09/03/1999, Ntb-Clips@..., jody
      ; Choose files to open from an open dialog box

      ; long line
      ^!Open ^?{(T=O;S=M;F="Text Files (*.txt)|*.txt|Outlines (*.otl)|*.otl|Ini Files (*.ini)|*.ini|Clipbook Library (*.clb)|*.clb")Open selected files}


      H=Checkbox Multi-Open
      ; 09/03/1999, Ntb-Clips@..., jody
      ; Choose files to open from checkbox list

      ^!ClearVariable %Files%

      ; long line till blank line
      ^!Set %Path%=^?{(T=D)Directory &path=E:\NTP\Documents\test\}; %Ext%=^?{(H=10)File &Types, wildcards OK: *.txt or *.*htm*;*.txt==_All Files^=*.*|Html Only^=*.*htm*|Text Only^=*.txt|Html & Text^=*.*htm*;*.txt|Outline^=*.otl|Clipbook Library^=*.clb|Ini^=*.ini}; %us%=^?{&Check files automatically in file list to open=_Yes^=_|No^=}

      ; Gets the first filename in the folder
      ^!Set %Full%=^$GetFileFirst(^%Path%;"^%Ext%")$

      ; Gets the remaining files and appends them all to %Files%.
      ; The ^%us% is set in the first line and adds an underscore
      ; if you choose to have the boxes checked for you.
      :Loop1

      ^!IfTrue ^$IsEmpty(^%Full%)$ DoArray
      ^!Append %Files%=^%us%^%Full%|
      ^!Set %Full%=^$GetFileNext$
      ^!GoTo Loop1

      ; Uses the files from above and makes a checkbox.
      :DoArray

      ^!CloseFileFind
      ^!SetArray %EditList%=^?{(T=A;H=25)Pick=^%Files%}
      ^!Set %p_Count%=^%EditList0%
      ^!Set %Index%=0

      ; Opens the files you checked.
      :Loop2
      ^!SetScreenUpdate Off
      ^!Inc %Index%
      ^!If ^%Index% > ^%p_Count% End
      ^!Open ^%EditList^%Index%%
      ^!Goto Loop2

      <--- Copy above this line, right --->
      <--- click over the Clipbook and --->
      <--- choose "Add from Clipboard" --->

      Happy Clip'n!
      Jody

      The NoteTab Clip List...
      mailto:Ntb-Clips-Subscribe@...
      mailto:Ntb-Clips-UnSubscribe@...
    Your message has been successfully submitted and would be delivered to recipients shortly.