HttpWebRequest request =
(HttpWebRequest)WebRequest.Create("http://www.teslaeurope.com/
default.htm");
// If required by the server, set the credentials.
//request.Credentials =
CredentialCache.DefaultCredentials;
//request.IfModifiedSince = DateTime.Parse("01-01-1990");
try
{
using (WebResponse response = request.GetResponse())
{
string lastModified = response.Headers["Last-
Modified"].ToString();
}
}
catch (WebException wex)
Dim req As Net.WebRequest = Net.WebRequest.Create("http://vbdotnetforums.com/Folder/File.ZIP")
req.Method = Net.WebRequestMethods.Http.Head
Dim res As Net.HttpWebResponse = CType(req.GetResponse, Net.HttpWebResponse)
Dim lastModified As Date = res.LastModified
res.Close()