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: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

setting the sheet.PageSetup.PrintTitleRows =

Thread ID:

Created:

Updated:

Platform:

Replies:

55101 Jan 23,2007 10:17 PM UTC Jan 25,2007 11:49 AM UTC WinForms 3
loading
Tags: XlsIO
Robert Chapman
Asked On January 23, 2007 10:17 PM UTC

I am creating excel reports and I am trying to set row 7 to repeat on each printed page. From what I can tell the way to do this is

File: PageSetup: Sheet: Rows to repeat at top
the value if set manually via excel is $7:$7

If I set sheet.PageSetup.PrintTitleRows = "$7:$7" in code I receive exception
Message "Value cannot be null.\r\nParameter name: input" string

StackTrace " at System.Text.RegularExpressions.Regex.Match(String input)\r\n at Syncfusion.XlsIO.Parser.Biff_Records.Formula.Area3DPtg..ctor(String strFormula, IWorkbook parent)\r\n at Syncfusion.XlsIO.Implementation.PageSetupImpl.ParsePrintTitleRows(String value)\r\n at Syncfusion.XlsIO.Implementation.PageSetupImpl.set_PrintTitleRows(String value)\r\n at prairieFyre.Reporting.Rendering.RenderExcel.FormatPrintArea() in C:\\Working\\CCS\\Source\\prairieFyre\\Reporting\\Rendering\\RenderExcel.cs:line 199\r\n at prairieFyre.Reporting.Rendering.RenderExcel.BuildSheet() in C:\\Working\\CCS\\Source\\prairieFyre\\Reporting\\Rendering\\RenderExcel.cs:line 184\r\n at prairieFyre.Reporting.Rendering.RenderExcel.Render(Object report) in C:\\Working\\CCS\\Source\\prairieFyre\\Reporting\\Rendering\\RenderExcel.cs:line 1248" string

I can set it to "B7:07" without exceptions however, when I open the report that gets saved and select File: Print Preview I receive an error
"Print titles must be continquous and complete rows or columns".

I am running XlsIO v4.402.0.51 and I have tried opening the file in both Excel 2007 and Excel 2003 (11.5612.5606) with the same result.

I currently have an item logged against me for this. I was wondering if you could tell me if the Print Title Rows functionality works in the version of xlsio that i have (4.402.0.51) and if not when it will work.

Thanks!

Melba Winshia [Syncfusion]
Replied On January 24, 2007 07:07 AM UTC

Hi Rob,

You can use PrintTitleColumns and PrintTitleRows properties of the PageSetup class to designate row and column headers that you want to have repeated on all pages of your printed worksheet. Please refer the following code snippet that illustrates the above:

[C#]

1) PrintTitleRows:

//Set Print Title Rows. Repeat row 7
sheet.PageSetup.PrintTitleRows = "$A$7:$IV$7";

2) PrintTitleColumns:

//Print Columns 1 to 3
sheet.PageSetup.PrintTitleColumns = "$A$1:$C$65536";

[VB.NET]

1) PrintTitleRows:

'Set Print Title Rows. Repeat row 7
sheet.PageSetup.PrintTitleRows = "$A$7:$IV$7"

2) PrintTitleColumns:

'Print Columns 1 to 3
sheet.PageSetup.PrintTitleColumns = "$A$1:C$65536"

Please refer the following sample which implements the above said feature:

printtitle.zip

Please take a look at the sample above and let me know if you have any other questions.

Regards,
Melba



Robert Chapman
Replied On January 24, 2007 07:26 PM UTC

Set the value as you indicated
Saved the report
Opened xls via excel
Select File: Print Preview and receive the error that
"PrintTitle must be congiuous and complete rows or columns"

I have attached the report so you can see the error



>Hi Rob,

You can use PrintTitleColumns and PrintTitleRows properties of the PageSetup class to designate row and column headers that you want to have repeated on all pages of your printed worksheet. Please refer the following code snippet that illustrates the above:

[C#]

1) PrintTitleRows:

//Set Print Title Rows. Repeat row 7
sheet.PageSetup.PrintTitleRows = "$A$7:$IV$7";

2) PrintTitleColumns:

//Print Columns 1 to 3
sheet.PageSetup.PrintTitleColumns = "$A$1:$C$65536";

[VB.NET]

1) PrintTitleRows:

'Set Print Title Rows. Repeat row 7
sheet.PageSetup.PrintTitleRows = "$A$7:$IV$7"

2) PrintTitleColumns:

'Print Columns 1 to 3
sheet.PageSetup.PrintTitleColumns = "$A$1:C$65536"

Please refer the following sample which implements the above said feature:

printtitle.zip

Please take a look at the sample above and let me know if you have any other questions.

Regards,
Melba




Syncfusion.zip

Administrator [Syncfusion]
Replied On January 25, 2007 11:49 AM UTC

Hi Rob,

I was able to reproduce the problem in the xls file given by you. However I created a test sample to reproduce the issue. But I was not able to reproduce the issue. Here is the sample that I used to test this issue.

printtitle.zip

Here is the output file generated:

Sample.xls

Could you please try running this sample and let us know if the same problem exists. If not could you please modify the sample to show the problem so that I can reproduce the issue. This would help us in investigating this issue further.

Best Regards,
Melba

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.

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

;