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.
Unfortunately, activation email could not send to your email. Please try again.

PDF Header and Flow Model

Thread ID:

Created:

Updated:

Platform:

Replies:

46489 Jul 13,2006 10:11 AM Jul 14,2006 01:55 PM Windows Forms 5
loading
Tags: PDF
Robert Rhoden
Asked On July 13, 2006 10:11 AM

I need to insert headers and footers into my document, but I also would like to use the flow model insteaed of the grid model. Is there a way to insert headers using the flow model, or is this supported only in the grid model?

Ajish [Syncfusion]
Replied On July 13, 2006 11:57 AM

Hi Robert, Thank you for your interest in Essential PDF. We do have options to set headers and footer in Flow Model. Please use the following code to set header. //Create a header paragraph IParagraph Headerpara=section.HeadersFooters.Header.AddParagraph(); This would return a paragraph object and using this you can add any paragraph item into the header section and it is the same with the footers. Here is a sample for your reference: DLSHeaderFooters.zip Please take a look at this sample and let me know if you have any further queries. Thanks, Ajish.

Administrator [Syncfusion]
Replied On July 13, 2006 03:25 PM

That worked for me. I do have two other small questions. Is there a way to tell which page of the Ducument I am on? I am looking to put a "Page x of y" line in my header. Also, is there an easy was to tell what the length of a given string is in pixels? I am trying to align a certain piece of dynamically generated text (read from an xml file), and need to know it''s length in order to position it correctly. >Hi Robert, > >Thank you for your interest in Essential PDF. We do have options to set headers and footer in Flow Model. > >Please use the following code to set header. > > >//Create a header paragraph >IParagraph Headerpara=section.HeadersFooters.Header.AddParagraph(); > > >This would return a paragraph object and using this you can add any paragraph item into the header section and it is the same with the footers. > >Here is a sample for your reference: DLSHeaderFooters.zip > >Please take a look at this sample and let me know if you have any further queries. > >Thanks, >Ajish. >

Ajish [Syncfusion]
Replied On July 13, 2006 05:28 PM

Hi Robert, Sorry for the inconvenience. 1) Currently it is not possible to insert page numbers in headers and footers in Flow. I have created a feature request regarding it you can trac the status of this issue from the following link. http://www.syncfusion.com/support/features/pdf/Default.aspx?ToDo=view&questId=1076 2) The Flow model approach will lay out the elements placed inside a PDF document automatically as they are added into the document. Also there are many formating options which would help you in positioning of the input string without calculating the size of the string. Can you please tell me how you like to align the text this would help me providing options available in flow model. Currently it is not possibe to measure the length. Please let me know if you have any questions. Thanks, Ajish.

Administrator [Syncfusion]
Replied On July 14, 2006 01:41 PM

I would like one piece of text on a line to be right aligned. >Hi Robert, > >Sorry for the inconvenience. >1) Currently it is not possible to insert page numbers in headers and footers in Flow. I have created a feature request regarding it you can trac the status of this issue from the following link. > >http://www.syncfusion.com/support/features/pdf/Default.aspx?ToDo=view&questId=1076 > >2) The Flow model approach will lay out the elements placed inside a PDF document automatically as they are added into the document. Also there are many formating options which would help you in positioning of the input string without calculating the size of the string. Can you please tell me how you like to align the text this would help me providing options available in flow model. Currently it is not possibe to measure the length. > >Please let me know if you have any questions. > >Thanks, >Ajish. > > >

Ajish [Syncfusion]
Replied On July 14, 2006 01:55 PM

Hi Robert, We do have option to set alignment of text. Here is a code to right align text. paragraph.ParagraphFormat.HorizontalAlignment = Syncfusion.DLS.HorizontalAlignment.Right; and here is a sample for your reference: http://www.syncfusion.com/Support/user/uploads/TextAlignment_2dc36f1a.zip Please take a look and let me know if you have any questions. Thanks, Ajish.

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.

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.

;