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

Using gridPrintCalendar

All,

I am using gridPrintCalendar to print a grid that contains a view of a calendar.

Questions:

1. Some of the horizontal and vertical lines of the grid are missing. Can this be fixed?
2. Is there a way to be able to select a printer rather then print to the default printer using the print view?

Thanks,

Scott


2 Replies

HA haneefm Syncfusion Team October 15, 2007 06:42 PM UTC

Hi Scott,

1. Some of the horizontal and vertical lines of the grid are missing. Can this be fixed?
>>>>>>>>>>>>>>>>>>>
We tried to reproduce this in V5.2, but could not get this issue. Maybe I am not following the steps that you are doing. The CalendarCells browser sample working fine here. Can you post a small sample showing this problem or tell us how to see it in the CalendarCells browser sample?

If you want to customize the printing in a grid, then you need to derive the GridPrintDocument and override its OnPrintPage method. In the override, don't call the base class. Place and draw the grids wherever you want it in the page layout. Please refer the following forums that helps in printing multiple grids in a page.

http://www.syncfusion.com/support/forums/message.aspx?&MessageID=68883

2. Is there a way to be able to select a printer rather then print to the default printer using the print view?
>>>>>>>>>>>>>>>>>>>
You can use the PrinterSettings class which has a PrinterName properly which specifies the printer to print to. Please refer to the following code snippet for detailed information:

GridPrintDocument pd = new GridPrintDocument(gridControl1, true); //Assumes the default printer
PrintPreviewDialog dlg = new PrintPreviewDialog() ;
dlg.Document = pd;
dlg.Document.PrinterSettings.PrinterName = "dsa";
dlg.ShowDialog();

Best regards,
Haneef


SG Scott Griswold October 16, 2007 01:07 PM UTC

Dear Haneef,

Thank you for your response. I think I found my problem. When you view the data grid in print view some of the lines that make up the calendar are missing. But when I print the grid everything is OK.

Thank you for your help.

Scott Griswold

>Hi Scott,

1. Some of the horizontal and vertical lines of the grid are missing. Can this be fixed?
>>>>>>>>>>>>>>>>>>>
We tried to reproduce this in V5.2, but could not get this issue. Maybe I am not following the steps that you are doing. The CalendarCells browser sample working fine here. Can you post a small sample showing this problem or tell us how to see it in the CalendarCells browser sample?

If you want to customize the printing in a grid, then you need to derive the GridPrintDocument and override its OnPrintPage method. In the override, don't call the base class. Place and draw the grids wherever you want it in the page layout. Please refer the following forums that helps in printing multiple grids in a page.

http://www.syncfusion.com/support/forums/message.aspx?&MessageID=68883

2. Is there a way to be able to select a printer rather then print to the default printer using the print view?
>>>>>>>>>>>>>>>>>>>
You can use the PrinterSettings class which has a PrinterName properly which specifies the printer to print to. Please refer to the following code snippet for detailed information:

GridPrintDocument pd = new GridPrintDocument(gridControl1, true); //Assumes the default printer
PrintPreviewDialog dlg = new PrintPreviewDialog() ;
dlg.Document = pd;
dlg.Document.PrinterSettings.PrinterName = "dsa";
dlg.ShowDialog();

Best regards,
Haneef

Loader.
Live Chat Icon For mobile
Up arrow icon