This is a migrated thread and some comments may be shown as answers.

To avoid duplication in file uploading

1 Answer 444 Views
AsyncUpload
This is a migrated thread and some comments may be shown as answers.
lekha
Top achievements
Rank 1
lekha asked on 07 Oct 2011, 12:56 PM
hi
I am using AsyncUpload. After selecting multiple images i have to upload all images to a rotator.

At the time of button  upload clicking i have to check any duplicate files occurs.
So I need the input files of radAsyncUpload,....  How can i get using script???

In RadUpload ,,,,,,,,radUpload.getFileInputs()  will get all fileinputs.. I tried it,But its not working in AsyncUpload

If anyone tried Please reply
Thanks in advance
Lekha








1 Answer, 1 is accepted

Sort by
0
Jayesh Goyani
Top achievements
Rank 2
answered on 05 Nov 2011, 11:22 AM
Hello,

foreach (UploadedFile NewFile in RadAsyncUpload1.UploadedFiles)
      {
          string strPath = Server.MapPath("UplodedFiles");
 
          FileInfo file = new FileInfo(strPath + "/"+ NewFile.FileName);
          if (file != null)
          {
              //file is alraedy in DB  with same name
          }
          else
          {
              // file is not exists
          }
 
      }


Thanks,
Jayesh Goyani
Tags
AsyncUpload
Asked by
lekha
Top achievements
Rank 1
Answers by
Jayesh Goyani
Top achievements
Rank 2
Share this question
or