Can we change the position Types

Hi,

We have 2 questions.

quesion 1:

Do we have the option to change the position types in the middle of the generation of the pdf at runtime.

To generate the pdf as per our requirement , we want to change the position types from one to the other (like auto --> relative, relative -->auto etc).

Question 2:

We want to generate the exact print of the screen having set of data at different positions in the form of pdf. We only have the x and y co ordinates of the data(static as in screen shot). But the challenge we have is some of the data can take more space and the other controls data should be displayed in the same order continuing them.

The data in the screen shot provided should be displayed in the pdf sequentially . But in the application(screen shot) after 3 lines of data, we need to scroll down and see. But in the pdf printed we have to display complete data.

For eg : In the screen shot if the header 1 has more text , it will exceed to more lines. But the x and y co-ordinates of the respective controls are static expecting only 3 lines of data for each control.

Then the y co-ordinate of the header 2 is to be increased and to be displayed after the header 1 in the same order with out overlapping.

Can this type of behavior be supported by aspose.

Hi Deepika,


Sorry for the delayed response. I am working over this query and will get back to you soon.

Hi Deepika,


Thanks for your patience and sorry for the delayed response.

I have gone through your requirements in details and in order to fulfill your requirements, you simply need to create PDF file using Aspose.Pdf.Generator namespace and use it to add objects in PDF file. Please note that all the objects added inside PDF file are added in Flow layout (from Top-Left to Bottom-Right). So in case Header element continues over multiple lines, the next object (text etc) will be placed after it.

You do not need to specify the alignment of each object explicitly, until you want to render them on specific side. Furthermore, if you need to place/display objects on specific location of the PDF file, then I would recommend you to please try using FloatingBox object. The FloatingBox is placed in PDF file using Obsolete positioning. For further details, please visit Working with Floating Box (Generator)