You are quite welcome, but only my grandkids friends call me "Mr."  ;-)

Mike


----- Original Message ----- 
From: "md" <[email protected]>
To: "RBASE-L Mailing List" <[email protected]>
Sent: Tuesday, December 27, 2011 1:01 AM
Subject: [RBASE-L] - Re: Counting items in a folder


: Thank you Mr. Byerley.  I do not have an immediate need but the
: "GetFileCount" may come in very handy in the future.
: Manuel de Aguiar
: M|D Enterprises
:
: -----Original Message-----
: From: [email protected] [mailto:[email protected]] On Behalf Of Mike 
Byerley
: Sent: Friday, December 23, 2011 1:20 PM
: To: RBASE-L Mailing List
: Subject: [RBASE-L] - Re: Counting items in a folder
:
:
:  Mike, etal,
:
:  The DLL and Helpfile are in the wild at:
: http://www.byerley.net/FileUtils.zip
:
:  There are Six function that perform file or directory actions and one
: function for changing the delimit character(s) for the functions life in 
the
: Current Session.  The helpfile is in pretty good shape.  Takes almost as
: long to do a helpfile as write a program I think..
:
: The functions:
:
:  STDCALL function 'GetFileAttr' (ptr TEXT (256)) : TEXT (64)
:  STDCALL function 'GetFileCount' (ptr TEXT (64), ptr TEXT (256)) : Integer
:  STDCALL function 'GetFileInfo' (ptr TEXT (64), ptr TEXT (256)) : TEXT
: (256)
:  STDCALL function 'GetFileList' (ptr text (64), ptr text (256)) : NOTE
:  STDCALL function 'GetFileSize' (ptr TEXT (256)) : TEXT (64)
:  STDCALL function 'GetVerInfo' (ptr TEXT (64), ptr TEXT (256)) : TEXT
: (1500)
:  and the delimit function:
: STDCALL function 'SetDelimiter' (ptr text (32)) : text (32)
:
:  There is an RMD file for each function demoing its useage.
:
: HTH
:
:
:
:
:
:
: ----- Original Message ----- 
:
: From: "Michael J. Sinclair" <[email protected]>
: To: "RBASE-L Mailing List" <[email protected]>
: Sent: Monday, December 19, 2011 3:45 PM
: Subject: [RBASE-L] - Re: Counting items in a folder
:
:
:: An Rbase homebrew would taste much better!
:: An enhancement to the chkfile function would be pretty cool....
:: Maybe something like...
:: (CHKFILE(filename,filesize,fileextenstion,filedate)) and have it return a
: 0 for nof iles, or an integer for the number of matching files.
:: Just my 2 cents worth.
:: Mike
:: PS: If you finish your dll, please let me know!
::
::
:: ________________________________
:: From: Mike Byerley <[email protected]>
:: To: RBASE-L Mailing List <[email protected]>
:: Sent: Monday, December 19, 2011 3:33 PM
:: Subject: [RBASE-L] - Re: Counting items in a folder
::
:: My dll returns filecount 0 if there are no files in the directory.
::
:: Jasons VBS uses the same APIs exposed through automation of the
:: FileSystemObject to get the various file properties.
::
:: My DLL supports all legal file wildcards.
::
:: I don't think a plugin from RBTI will give them much bang for the buck
: since
:: there are several homebrew workarounds for most of what you want.
::
::
::
::
:: ----- Original Message -----
:: From: "Michael J. Sinclair" <[email protected]>
:: To: "RBASE-L Mailing List" <[email protected]>
:: Sent: Monday, December 19, 2011 3:07 PM
:: Subject: [RBASE-L] - Re: Counting items in a folder
::
::
:: One limitation of the chkfile function is that is does not support wild
:: cards. Unless I know in advance the exact filename I am looking for, that
:: "Will give unpredictable results". Can you think of a way that I could
: check
:: to see if any file exists in a folder?
:: Mike
::
::
:: ________________________________
:: From: Mike Byerley <[email protected]>
:: To: RBASE-L Mailing List <[email protected]>
:: Sent: Monday, December 19, 2011 1:25 PM
:: Subject: [RBASE-L] - Re: Counting items in a folder
::
:: You can check for existance with RBase ChkFile function.
::
:: Already have a 97% finished DLL that has a variety of File functions
:: including FileSize, FileCount (based on one or a series of File
: extensions),
:: FileVersionInfo and so on. Maybe in a few days or a week (depending on 
how
:: much interruption holiday stuff does) I can get it done sufficiently to
: put
:: in the wild for use. I do know it's been long enough since I worked on it
:: that the source code doesn't match what I started in the Help File, but
: like
:: I said, it's close to done.
::
::
::
::
::
:: ----- Original Message -----
:: From: "Michael J. Sinclair" <[email protected]>
:: To: "RBASE-L Mailing List" <[email protected]>
:: Sent: Monday, December 19, 2011 12:08 PM
:: Subject: [RBASE-L] - Re: Counting items in a folder
::
::
:: Hi Mike,
::
:: There are a few scenarios where this would be helpful.
::
:: First checking for the existance of any file in the folder would be
: helpful
:: for error handling.
::
:: Sometimes files are created which should have a minmum size if the data 
is
:: good. Corrupt data ends up creating a file that is smaller than a certain
:: size. Being able to check for the existance of any files with a filesize
:: that is smaller than a predetermined limit would help the application to
:: call for help, call a different app, send an email etc.
::
:: Looking for the existance of a certain number of files such as jpg files
:: could trigger an app to create a single pdf file out of the group of jpg
:: files.
::
:: I would like to be able to count the number of files using various
: criteria
:: and display them by changing the properties (color and text) of certain
:: buttons that do things to the files, ie red for no files, green plus a
:: number to indicate the presence of a certain number of files in a folder.
::
:: Mike
::
::
::
:: ________________________________
:: From: Mike Byerley <[email protected]>
:: To: RBASE-L Mailing List <[email protected]>
:: Sent: Monday, December 19, 2011 9:39 AM
:: Subject: [RBASE-L] - Re: Counting items in a folder
::
:: Mike,
:: Could you elaborate a bit on what you are trying to do? Filesize or
:: Filecount are pretty easy, but why do you want to search or display a 
file
:: that is of a certain size?
::
::
::
:: ----- Original Message -----
:: From: "Michael J. Sinclair" <[email protected]>
:: To: "RBASE-L Mailing List" <[email protected]>
:: Sent: Sunday, December 18, 2011 8:38 AM
:: Subject: [RBASE-L] - Counting items in a folder
::
::
::: Hi All,
::: How would you count the number of files in a folder and capture that
: value
:: into a variable (assume no subfolders)?
::: (If there were a PLUGIN for that, it would be great if the PLUGIN had 
the
:: ability to specify file characteristics that would limit the count, such
: as
:: count only files that are a certain size or created on or after a certain
:: date, had a certain extension, etc.)
::: Mike
:
: 


Reply via email to