...
> Mr. Arnold wrote:
>> "Arne Vajhj" <a
@vajhoej.dk> wrote in message
>>
news:466766cb$0$90262$14726298@news.sunsite.dk...
>>> Gaurav wrote:
>>>> Hi...I have a requirement to find the first file within a directory. I
>>>> know we can use the GetFiles() method of Directory class, but am a
>>>> little stuck up with the syntax.
>>>> Can somebody plz let me know who this can be done?
>>> You asked the same question a couple of hours ago and
>>> got two replies.
>>> Why not start from there instead of starting a new thread.
>> Do you want me to step on the OP for you? I can certainly do that. It
>> would be a pleasure. :)
> That would not be necessary.
I am at your calling when needed, just call with a top post. :)
What is meant by "the first file within a directory"? First in what sense?
The one that happens to be the first entry stored in the directory? Why is
that useful? Or do you mean the first after the files are sorted by some
criterion, such as name or age?
-----------------------------------------------Reply-----------------------------------------------
On Jun 7, 9:13 am, "Michael A. Covington"
<l
@ai.uga.edu.for.address> wrote:
> What is meant by "the first file within a directory"? First in what sense?
> The one that happens to be the first entry stored in the directory? Why is
> that useful? Or do you mean the first after the files are sorted by some
> criterion, such as name or age?
Does the 'First' file mean the first file you can see in windows
explorer. As per default setting files are sorted based on FileName.
Clarify what exactly you want to achieve. If it's filename sort order
you can use Array.Sort method as pointed out by Arnold.