Пример #1
4
 protected void ASPxUploadControl1_FileUploadComplete(object sender, FileUploadCompleteEventArgs e)
 {
     UploadFiles upf = new UploadFiles();
     string path = upf.UploadImage(e.UploadedFile.FileName);
     e.UploadedFile.SaveAs(Server.MapPath(path));
     ASPxUploadControl1.JSProperties["cpImgUrl"] = path;
 }
 protected void ASPxUploadControl1_FileUploadComplete(object sender, FileUploadCompleteEventArgs e)
 {
     if (e.IsValid)
     {
         ASPxUploadControl uploadControl = sender as ASPxUploadControl;
         UploadFiles upf = new UploadFiles();
         string path = upf.UploadFile(e.UploadedFile.FileName, cultureId, uploadControl);
         e.UploadedFile.SaveAs(Server.MapPath(path + e.UploadedFile.FileName), true);
     }
 }
 protected void ASPxUploadControl2_FileUploadComplete(object sender, DevExpress.Web.FileUploadCompleteEventArgs e)
 {
     if (e.IsValid)
     {
         ASPxUploadControl uploadControl = sender as ASPxUploadControl;
         UploadFiles upf = new UploadFiles();
         string path = upf.UploadTeachTable(e.UploadedFile.FileName, undirectTeachId, uploadControl, undirectTeachMId);
         e.UploadedFile.SaveAs(Server.MapPath(path + e.UploadedFile.FileName), true);
     }
 }
Пример #4
0
 public void UploadFile(ASPxUploadControl uploadCtrl, DevExpress.Web.FileUploadCompleteEventArgs e, string map)
 {
     UploadFiles upf = new UploadFiles();
     string path = upf.UploadFileDoc(e.UploadedFile.FileName, DocTypeId, uploadCtrl, map);
     e.UploadedFile.SaveAs(Server.MapPath(path + e.UploadedFile.FileName), true);
 }
 protected void ASPxUploadControl1_FileUploadComplete(object sender, FileUploadCompleteEventArgs e)
 {
     UploadFiles updoc = new UploadFiles();
     string path = updoc.UploadDoc(e.UploadedFile.FileName);
     e.UploadedFile.SaveAs(Server.MapPath(path));
 }