protected void btnImport_Click(object sender, EventArgs e) { Host host = new Host(); string csvFilePath = Server.MapPath("~") + Path.DirectorySeparatorChar + "data" + Path.DirectorySeparatorChar + "csvupload" + Path.DirectorySeparatorChar + "hosts.csv"; FileUpload.SaveAs(csvFilePath); if (Environment.OSVersion.ToString().Contains("Unix")) Syscall.chmod(csvFilePath, (FilePermissions.S_IWUSR | FilePermissions.S_IRGRP | FilePermissions.S_IROTH | FilePermissions.S_IRUSR)); host.Import(); Master.Msgbox(Utility.Message); }