<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=windows-1252">
<META content="MSHTML 6.00.2600.0" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV> My earlier testing of John's code (ref my previous
message dated 20-May-2003) was based upon setting .FileType as
msoFileTypeAllFiles (commenting out the line related to .FileName).</DIV>
<DIV> </DIV>
<DIV> On further testing of this code, certain relevant
findings are given below -</DIV>
<DIV> </DIV>
<DIV> (a) If the line [ .FileName = "*.mda; *.mdb; *.mde;
*.ldb" ] is enabled (instead of the one related to .FileType) the
result of search count is zero.</DIV>
<DIV> Reason - No match is
possible for above type of string.</DIV>
<DIV> Solution - Use homogeneous string
without delimiters.e.g.</DIV>
<DIV>
.FileName =
"*.mdb"</DIV>
<DIV> </DIV>
<DIV> (b) Starting letter of folder name does not
matter.</DIV>
<DIV> </DIV>
<DIV> (c) If any of the file names has special
characters(quite often the case with web documents), there is an error message
reg syntax error, the loop is exited and no further information
gets inserted in the table. Sometimes this problem occurs for
date fields as well. Moreover, the cursor remains stuck indefinitely in the
hourglass mode.</DIV>
<DIV> Reason - SQL string does not get
concatenated properly.</DIV>
<DIV> Solution - Avoid use of SQL string as
the likelihood of unforeseen syntax complications can never be completely ruled
out. In lieu rst.Add method could be considered. </DIV>
<DIV> Note - As an experiment, the code was run after
modifying the SQL so as to insert "A" for FilePath and "B" for FileName fields
only, ignoring the date fields. There was no problem. Approx 7,000 files
were found in all (main folder plus subfolders).The numbers shown in the message
box tallied with the records appended to the table.</DIV>
<DIV> </DIV>
<DIV> John may like to modify the code suitably, addressing
the points brought out above and distribute the revised version. While doing so,
he may consider incorporating folder browsing feature so that there is
no need for editing code module (for starting folder path).</DIV>
<DIV> </DIV>
<DIV>Regards,</DIV>
<DIV><STRONG>A.D.Tejpal</STRONG></DIV>
<DIV><STRONG>--------------</STRONG></DIV>
<BLOCKQUOTE
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV style="FONT: 10pt arial">----- Original Message ----- </DIV>
<DIV
style="BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: black"><B>From:</B>
<A title=roz.clarke@donnslaw.co.uk href="mailto:roz.clarke@donnslaw.co.uk">Roz
Clarke</A> </DIV>
<DIV style="FONT: 10pt arial"><B>To:</B> <A title=accessd@databaseadvisors.com
href="mailto:'accessd@databaseadvisors.com'">'accessd@databaseadvisors.com'</A>
</DIV>
<DIV style="FONT: 10pt arial"><B>Sent:</B> Thursday, May 22, 2003 14:32</DIV>
<DIV style="FONT: 10pt arial"><B>Subject:</B> RE: [AccessD] Grab
Filenames</DIV>
<DIV><BR></DIV>This may be the case, but wouldn't explain why Charlotte got 0
files<BR>returned in her search...<BR><BR>-----Original Message-----<BR>From:
Ron Allen [mailto:chizotz@charter.net] <BR>Sent: 21 May 2003 17:47<BR>To: <A
href="mailto:accessd@databaseadvisors.com">accessd@databaseadvisors.com</A><BR>Subject:
Re: [AccessD] Grab Filenames<BR><BR><BR>Is there a limit to the number of
directories and <BR>subdirectories that can be searched/found this way? There
<BR>used to be some absolute limits to the number of <BR>directories in the
root and other stuff... I'm wondering <BR>if there is a limit, artificial or
not, being hit here. <BR>Does it by chance find "exactly" 128, or 256, or 512,
etc. <BR>folders/files before choking?<BR><BR><BR>>-----Original
Message-----<BR>>From: Roz Clarke
[mailto:roz.clarke@donnslaw.co.uk]<BR>>Sent: Wednesday, May 21, 2003 11:50
AM<BR>>To: <A
href="mailto:'accessd@databaseadvisors.com'">'accessd@databaseadvisors.com'</A><BR>>Subject:
RE: [AccessD] Grab Filenames<BR>><BR>><BR>>Interesting fact just
spotted... All of the directories<BR>>it doesn't look in<BR>>are those
which come after M in the alphabet and are <BR>>coming from the
root<BR>>folder, and their sub-directories.<BR>><BR>>It's as if it
gets so far and just stops. Any way to<BR>>troubleshoot what
it's<BR>>doing? Why it's breaking?<BR></BLOCKQUOTE></BODY></HTML>