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

Getting a list of files in a directory, making Thumbnails, create index page

Expand Messages
  • Jeffery Scism
    I have modified a previous clip to GRAB Image file names, and make the image file names into a INDEX page with Thumbnails (Thanks JODY) (What I need help on is
    Message 1 of 1 , May 30 7:11 AM
    • 0 Attachment
      I have modified a previous clip to GRAB Image file names, and make the
      image file names into a INDEX page with Thumbnails (Thanks JODY)


      (What I need help on is getting it to run the EasyThumbs at the same
      time and create Thumbs in a "tn" folder in the image directory. so the
      final page is "ready to run".)

      Jeff


      ; Last updated on 05-28-2005, (original by: Support@..., Jody),
      revised- Scismgenie@... (Jeff Scism)
      ^!ClearVariables
      ^!Set %Dir%=^?{(T=D)&Directory}; %Subs%=^?{&Include Sub-directories
      (v4.83 or better)=Yes^=+|_No^=}; %Types%=^?{File &type(s)
      *.txt;*.htm*;*.dll;*.jpg;*.gif;*.exe=*.jpg*}; %Attr%=^?{&Attributes, A:
      Archive, H: Hidden, R: Read-only, S: System=_All^=*|AHRS};
      %Sort%=^?{&Sort order=Date|Name|Size|_Type|UnSorted}; %Rev%=^?{&Reverse
      sort order=Yes^=Rev|_No^=}; %NewDoc%=^?{&Output for time,
      etc.=Infobox|_New Document^=1}
      ^!Set %TimeStart%=^$GetDate(nn:ss)$
      ^!SetHintInfo Getting Directory Information...
      ^!SetArray
      %FileList%=^$GetFiles("^%Subs%^%Dir%";^%Types%;^%Attr%;^%Rev%^%Sort%)$
      ^!Set %Count%=^%FileList0%
      ^!Set %Index%=0; %FileCount%=0
      ^!Toolbar New Document

      :Loop
      ^!Inc %Index%
      ^!If ^%Index% > ^%Count% Stats
      ^!Set %FileName%=^%FileList^%Index%%

      ; This is the link. Just add the HTML that you want on each link.
      <a href="^$GetFileName("^%FileName%")$"><Img
      Src="tn_^$GetName("^%FileName%")$"></a><BR>^%nl%
      ^!Inc %FileCount%
      ; may go a tad bit faster if next line ;commented, especially on large
      folders /ja
      ^!SetHintInfo ^%FileCount%
      ^!Goto Loop

      :Stats
      ^!SetHintInfo Standby... It might take awhile; path\files being parced
      ^!IfTrue ^%NewDoc% Skip_3
      ^!SetWizardTitle ~^$StrFill(" ";60)$ http://www.notetab.net ^$StrFill("
      ";66)$~
      ^!Info [L]Total files: ^%FileCount%^pTotal size:
      ^%TotalSize%^%pv%^p^p^%Files%
      ^!Goto End
      ; the reason it takes some time after the New doc is made and
      ; the files being inserted is because NoteTab passes the lines
      ; of text off to Windows for parsing - doing many folders with
      ; lots of files takes some time /ja (per Eric Fookes)
      ^!Set %CollectDone%=^$GetDate(nn:ss)$
      ^!Toolbar New Document
      ^!InsertText Total files:
      ^%FileCount%^p^p^%Files%^p^$GetDate(C)$^pCollection Start:
      ^%TimeStart%^pCollection End: ^%CollectDone%^p
      ^!Jump 1
      ; The above just gives you some stats and below goes back to the list.
      ^!Document Prev
      ; Do a Document to HTML here or jump 1 and paste the heading
      ; stuff and jump doc_end for the footer. If you add to this
      ; file then adjust the links to HTML
      ^!Save As

      --
      ~~

      Jeffery G. Scism, IBSSG

      "He who throws stones is providing an enemy with ammunition, and an idea of it's application."

      Benjamin Franklin


      S250 DNA Project
      Crawley DNA Project
      International Blacksheep Society of Genealogists
      Montgomery County Indiana USGenWeb site

      (member of:) USGWP-CC mailing list mailto:USGWP-CC@...
    Your message has been successfully submitted and would be delivered to recipients shortly.