0

我正在使用 MOVEit .NET 客户端库版本 9.0.0.0 将一些文件上传到服务器。但我收到错误“无法访问已处置的对象。对象名称:'System.Net.HttpWebResponse”

有谁知道如何解决这个问题。

代码类似于https://docs.ipswitch.com/MOVEit/Transfer2021/Api/dotNet/html/254a072a-4c2e-4030-59a1-522baf871996.htm上的文档

Client oAPI = new Client();
oAPI.Host = "<host>";
oAPI.Secure = true;
 
if (oAPI.Signon("<login>", "<password>"))
{
Console.WriteLine("Signed on ok");
string newID = oAPI.FileUpload(@"<filePath>", oAPI.HomeFolderPath);
if (newID != "0")
{
Console.WriteLine("Uploaded file OK: {0}", newID);
}
else
{
Console.Error.WriteLine("Error uploading file: {0}", oAPI.StatusDescription);
}
4

0 回答 0