示例#1
0
        public static void UploadFile(string filePath, string destFileName, IBackgroundWorkContext context)
        {
            //if (DestinationStreamCreator == null)
            //{
            //    throw new InvalidOperationException("未设置DestinationStreamCreator。");
            //}

            //FileUploader.UploadFile(filePath, destFileName, (i, s) => context.SetProgress(i, s));
            FileUploader.UploadFile2(filePath, destFileName, (i, s) => context.SetProgress(i, s));
        }
 public void UploadFile(string filePath, string destFileName, IBackgroundWorkContext context)
 {
     _fileUploader.UploadFile(filePath, destFileName, (i, s) => context.SetProgress(i, s));
 }
 private void DoUpload(BindableMediaFileItem item, IBackgroundWorkContext c)
 {
     this.MediaFileService.UploadFile(item.FilePath, item.FileName, c);
     this.MediaFileService.Add(item.Entity, App.Current.Name);
 }