Hi there,
The ModTime() method (with the comments I added) is as follows:
public virtual DateTime ModTime(string remoteFile)
{
CheckConnection(true);
FTPReply reply = control.SendCommand("MDTM " + remoteFile);
lastValidReply = control.ValidateReply(reply, "213");
// parse the reply string ...
DateTime ts = DateTime.ParseExact(lastValidReply.ReplyText, tsFormat, CultureInfo.CurrentCulture.DateTimeFormat);
///The above DateTime variable 'ts' has the UTC time, but the program
///converts it to UTC once again and returns, which thus produces
///incorrec time.
return ts.ToUniversalTime();
///So ,
///Return the ts because it is in UTC format. No need to convert into UTC
///onceagain.
return ts;
}
Am I correct!!!! ,,it works like that, atleast for the ftp sites to which I connect.
I would appreciate if you could agree or disagree with me :)
Thank you,
Srinivas Varukala