|
dev
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Get file informations form web URLsI used the FileInfo class to obtain informations about files in the
file system. I would like to have the same informations for a file in a web url, but I cannot use FileInfo. I discovered WebClient from the System.Net namespace, but this gives me a FileStream in return and not a FileInfo. Any way to convert a FileStream into FileInfo? Or rather any other way to have these informations? Thanks in advance, ema Hello, Emanuele!
EO> I used the FileInfo class to obtain informations about files in the EO> file system. EO> I would like to have the same informations for a file in a web url, but EO> I cannot use FileInfo. EO> I discovered WebClient from the System.Net namespace, but this gives me EO> a FileStream in return and not a FileInfo. EO> Any way to convert a FileStream into FileInfo? Or rather any other way EO> to have these informations? You can use UNC path to obtain the same FileInfo. File path will look like \\server\folder\file.ext Hello Vadym,
UNC path? Where can I get it? The only UNC method I found on DSN is from namespace System.Data.SqlServerCe !! ema Emanuele Ornella wrote:
> I used the FileInfo class to obtain informations about files in the No, there is not. Access via an URL generally doesn't provide any > file system. > I would like to have the same informations for a file in a web url, > but I cannot use FileInfo. > I discovered WebClient from the System.Net namespace, but this gives > me a FileStream in return and not a FileInfo. > > Any way to convert a FileStream into FileInfo? Or rather any other way > to have these informations? information about the resource other than a name and possibly a last-modified date. If you need more information than that, you need more access than you're going to get via a URL. -cd
Show quote
> No, there is not. Access via an URL generally doesn't provide any
> information about the resource other than a name and possibly a > last-modified date. If you need more information than that, you need more > access than you're going to get via a URL. > Thanks! ema |
|||||||||||||||||||||||