Angular error: zoomFactor

Hi

I have an error when I try to test the pdf viewer component. 

package.json
 "@syncfusion/ej2-angular-pdfviewer": "^18.4.31",
 
Net core 3.1
https://www.syncfusion.com/kb/11063/how-to-create-the-pdf-viewer-web-service-application-in-net-core-3-0-and-above-version
 

home.component.html
  <ejs-pdfviewer id="pdfViewer" 
  [serviceUrl]="service" 
  [documentPath]="document"
  style="height:640px;display:block"></ejs-pdfviewer>

home.component.ts
import { ComponentOnInit } from '@angular/core';

@Component({
  selector: 'app-home',
  templateUrl: './home.component.html',
  styleUrls: ['./home.component.scss'],
})
export class HomeComponent implements OnInit {

  public service = 'https://localhost:5001/PdfViewer';
  public document = '01810_ru_ZH_Samara_V1_WIFI.pdf';
  constructor() {}

  ngOnInit() { }
}


 
 Angular error ( in chrome console)
 {type: "https://tools.ietf.org/html/rfc7231#section-6.5.1",…}
errors: {$.zoomFactor: [,…]}
$.zoomFactor: [,…]
0: "The JSON value could not be converted to System.Collections.Generic.Dictionary`2[System.String,System.String]. Path: $.zoomFactor | LineNumber: 0 | BytePositionInLine: 59."
status: 400
title: "One or more validation errors occurred."
traceId: "|54936ac6-4bea9b799053059d."
type: "https://tools.ietf.org/html/rfc7231#section-6.5.1"

Best Regards

Diego



5 Replies

AA Akshaya Arivoli Syncfusion Team January 5, 2021 10:12 AM UTC

Hi Diego, 

Thank you for contacting Syncfusion Support. 

We were unable to reproduce the reported issue with the provided details. We have shared the sample in which we have tried in the below link, 


Kindly try it and revert with more details about your issue and the modified sample if you have any concerns about this. 

Regards, 
Akshaya 



DD Diego Dorado Fernández January 5, 2021 11:45 AM UTC

Hi Akshaya 

I don't know why my code failed, but with the example you sent me it works perfectly. 

Best regards


AA Akshaya Arivoli Syncfusion Team January 6, 2021 08:37 AM UTC

Hi Diego,  

Thank you for your update. 

We were glad to know that the reported issue was resolved. Kindly revert with more details, if you need any assistance in the future. 

Regards, 
Akshaya  



YU Yul April 17, 2021 10:04 AM UTC

Can you please provide a similar example for Blazor client side?




DM Dhivyabharathi Mohan Syncfusion Team April 19, 2021 09:03 AM UTC

Hi Yul, 
 
 
We have shared the Blazor client application. Please refer the sample from the below link. 
 
 
 
 
Kindly try this and revert us, if you have any concerns. 
 
 
Regards, 
Dhivya. 


Loader.
Up arrow icon