FileSize - HowTo
- From: "mosscliffe" <page77.office@xxxxxxxxxxxxxx>
- Date: 29 Jun 2006 06:24:39 -0700
I get a list of filenames from a directory with the following code, but
I can not work out how to get the filesize of the filename I have just
found.
I guess it is fileinfo.length, but I can not see how to turn my
filename(string) into a statement which would give me the filesize -
the brain is very slow today. Any help gratefully appreciated.
Dim files() As String = System.IO.Directory.GetFiles(root,
patt)
dim filename as string
Dim f As String
For Each f In files
filename = System.IO.Path.GetFileName(f)
DropDownList1.Items.Add(filename)
..... GET FILESIZE OF ABOVE FILE and add to array
filesizes
Next
.
- Follow-Ups:
- Re: FileSize - HowTo
- From: Juan T. Llibre
- Re: FileSize - HowTo
- From: Ray Booysen
- Re: FileSize - HowTo
- Prev by Date: how to track line number of a text file through coding?
- Next by Date: Re: Missing a virtual directory but which one - MachineToApplication error.
- Previous by thread: how to track line number of a text file through coding?
- Next by thread: Re: FileSize - HowTo
- Index(es):
Relevant Pages
|