.NET Framework Bookmark and Share   
 index > Network Class Library (System.Net) > Reading file properties from Blob server
 

Reading file properties from Blob server

Hello, I'm reading image content from Blob server using below mentioned APIs and saving the file on local machine. Now while saving I also want to read "File Created" and "File Modified" time stamp properties from my Blob server and want to set same properties on file downloaded and saved on my local machine.

WebRequestwebRequest = WebRequest.Create(urlAddress);
WebResponse webResponse = webRequest.GetResponse();
Stream stream = webResponse.GetResponseStream();

Please suggest how Can I read FileSystemInfo using WebRequest??

Thanks


neha_er
Neha_er

The HTTP protocol does provide a standard way to pass file metadata to the clients, but the server has to support it as well.

If this is a standard HTTP server, then you should be able to get the "File modified" timestamp from the "Last-Modified" HTTP header. However, there is no header that reflects the "File created" time. You need to modify the server to send the "File created" timestamp in a custom HTTP header.


feroze
--
My blog
Feroze Daud

You can use google to search for other answers

Custom Search

More Threads

• SFTP - Help please!
• What is the visible IP Address seen by SMTP server?
• WebRequest.DownloadFile behind proxy
• How to locate Live Server URL
• Append header with internal Request, Response
• Need help retrieving a udp response after sending a udp command
• send http-form with data, work on requested side
• Couldn't connect to remote server
• Download all swf files from web page
• How to set encoding of the send data of an HttpWebRequest