We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: June 24, 2019).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Chunk Upload doesn't add header and upload failed from the second times.

Thread ID:

Created:

Updated:

Platform:

Replies:

145722 Jun 10,2019 08:15 AM UTC Jul 5,2019 12:28 PM UTC WinForms 3
loading
Tags: General
lorryl
Asked On June 10, 2019 08:15 AM UTC

Hi,

My WebAPI is based on the windows authorization, and the webapi is in the computer IIS,
and my web site is in the another computer IIS, so when I used to use chunk upload, I need to add header  with the credentials is true.

When I upload the file that file size is larger than chunk size, it doestnot work when process the second save parts, only the first save file part is success.
I posted a thread in last year, and I updated the syncfusion to lastest, but the problem is still exists.

Please fix this problem in hurry, and reply to me the fixed ETD, thanks!





The first upload part is success:


But the second part is 401 error:




Prince Oliver [Syncfusion]
Replied On June 11, 2019 09:10 AM UTC

Hello Lorryl, 

Good day to you. 

We have checked your reported scenario. You have used the uploading event to add additional headers in the chunk uploader and hence you are facing this issue. We have provided chunkUploading event which fires for every chunk upload process gets started. To add the additional parameter with the current request, we suggest you add the headers in the chunkUploading event. Please refer the below code snippet. 

[html] 
<ejs-uploader #chunkupload id='chunkfileupload' [maxFileSize]=104857600 [autoUpload]=false [asyncSettings]='path' [dropArea]='dropElement' (pausing)='onPausing($event)' (resuming)='onResuming($event)' (removing)='onFileRemove($event)'(chunkFailure)='onBeforefailure($event)' (chunkUploading)='onChunkuploading($event)'> </ejs-uploader> 


[ts] 
public onChunkuploading(args: any): void { 
  if (args.currentRequest) { 
    args.currentRequest.withCredenials = true; 
  } 
} 

Please check the above solution in your end and let us know if you need any further assistance on this. 

Regards, 
Prince 


lorryl
Replied On July 4, 2019 08:01 AM UTC

Hi,

The "ChunkUploading" is working fine, thank you very much!

Another question:
I want to call the upload file save function of the web API in windows applications with the C# code, 
how to loop to call the upload file save function because it's chunk uploading, do you have a demo in c#?


Farjana Parveen Ayubb [Syncfusion]
Replied On July 5, 2019 12:28 PM UTC

Hi Lorryl, 
 
Thanks for your update. 
 
We have analyzed your query, but this is not related to our Syncfusion controls. You can check the below link for further reference of your query. 
 
 
Regards, 
Farjana Parveen A 


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

Live Chat Icon For mobile
Live Chat Icon