How to upload file to the shared network folder using C# in ASP.Net

Last Reply 2 months ago By aspvijay04

Posted 2 months ago

 

 pathAndFile ="file://172.27.16.20/import/";

or

pathAndFile = "\\\\dmspams\\import\\";

pathAndFile += drpborrower.SelectedItem.ToString() + "_" + drpbank.SelectedItem.ToString() + "_" + drpdoctype.SelectedItem.ToString() + "_" + drpfy.SelectedItem.ToString() + "_" + drpmonth.SelectedItem.ToString() + "_" + txtdate.Text + ext;
//FileUpload1.SaveAs(pathAndFile);
if (System.IO.File.Exists(pathAndFile))
{
Page.RegisterStartupScript("OnClick", "<script>alert('This File Name is Already Available!')</script>");
}
else
{
fi.MoveTo(pathAndFile);

}

 

another

You are viewing reply posted by: aspvijay04 2 months ago.
I agree, here is the link: https://www.e-iceblue.com/Introduce/spire-office-for-net-free.html