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. Image for the cookie policy date

Print problems


I have problems with printing grid.

1. I am having different grids in my program. When I try to print first grid for the first time - I get data correctly. After that I am trying to print different grid I get data from WebAPI but in print dialog I see "No records to display" and header like previous grid:
First try to print:

Second try to print different grid:

But with this try in my Network tab I can see that data from WebAPI was get correctly:

2. I am getting data for my grid using WebAPI. I am getting  records and also count. How can I get this count number in my component?

1 Reply

TS Thavasianand Sankaranarayanan Syncfusion Team August 23, 2019 10:42 AM UTC

Hi AC, 
Greetings from Syncfusion support. 
Query 1: Showing “No records to display” when we click for print Grid.  
We have prepared a sample with your mentioned scenario but unfortunately we are unable to reproduce the issue from our end. 
Please provide the following details for better assistance. 
  1. Share the complete Grid rendering code.
  2. If possible try to reproduce the issue in the attached sample.
  3. Whether the mentioned issue is reproducing when we click for print else if we do some other operations after clicking the print.  
  4. Do you have WebAPI adaptor in both Grid sample ?
Query 2: How can I get this count number in my component? 
We can get the total records count in Grid by using the pageSettings API in Grid. 
In the below code example we have get the total records count in an external button click event. 
<button id="RecordCount" (click)="RecordCountClick()">Get total record count</button> 
export class AppComponent { 
    . . . . 
    RecordCountClick(args) { 
    . . . . 
We have prepared  a simple sample in the following link. 
Thavasianand S. 

Live Chat Icon For mobile
Up arrow icon