Xojo Conferences
MBSOct2019CologneDE

Getting all the items in a folder (Real Studio network user group Mailinglist archive)

Back to the thread list
Previous thread: Alternative to FSpExchangeFiles?
Next thread: Re: FAQ [V4RB] Simple Programming Style Question


"I feel the need for speed" (string)   -   Jan Erik Moström <
  Getting all the items in a folder   -   Palaniappan Chellappan
   Re: Getting all the items in a folder   -   Boris Segerstahl

Getting all the items in a folder
Date: 08.05.02 07:52 (Wed, 8 May 2002 12:22:49 +0530)
From: Palaniappan Chellappan
Hi all,

I was just wondering if any of you know how to make a folderitem of all
the items in a folder. For example, if i want to handle all the items in
a folder with the extension .html, what should i do?

Thanks,
Palaniappan

---
Subscribe to the digest:
<mailto:<email address removed>>
Unsubscribe:
<mailto:<email address removed>>

Re: Getting all the items in a folder
Date: 08.05.02 08:33 (Wed, 8 May 2002 10:33:11 +0300)
From: Boris Segerstahl

On Wednesday, May 8, 2002, at 09:52 AM, Palaniappan Chellappan wrote:
>
> I was just wondering if any of you know how to make a folderitem of all
> the items in a folder
> . For example, if i want to handle all the items in a folder with the
> extension .html, what should i do?

"A folderitem" probably has to be an array? Off the top of my head
something like this:
------------------------
dim f, folarr(-1) as folderitem
dim idx as integer

f =
GetFolderItem("whatever") //
the folder you want to work with
for idx = 1 to
f.count //
take every item in the folder
if f.exists and idx <= f.count and f.Item(idx)<>Nil then // you
can never check too many things
if instr(f.item(i).name,".html") > 0
then // if you find the extension
folarr.append
f.item(i) // add it to the
array
end if
end if
next
--------------------------
It is works the you have in folarr folderitems for all html-files in
your folder. After that it should be downhill all the way. Take it as
pseudocode. I have never tried it. Would be good to know if it works.

Boris
I hate unmatched end ifs



>
> Thanks,
> Palaniappan
>
> ---
> Subscribe to the digest: <mailto:realbasic-nug-
> <email address removed>>
> Unsubscribe:
> <mailto:<email address removed>>

---
Subscribe to the digest:
<mailto:<email address removed>>
Unsubscribe:
<mailto:<email address removed>>