PDFsharp & MigraDoc Foundation
http://forum.pdfsharp.de/

create table and content?
http://forum.pdfsharp.de/viewtopic.php?f=2&t=2635
Page 1 of 1

Author:  zuum [ Mon Nov 04, 2013 4:08 pm ]
Post subject:  create table and content?

Hi,

I want to migrate my iTextSharp code to MigraDoc because of licensing problems.
It’s pretty easy to create simple text PDFs using MigraDoc, but creating a table (what I want to achieve) does not work for me like it should.
I tried to follow the tutorial at http://www.pdfsharp.net/wiki/Invoice-sample.ashx, but I don’t really understand how that works.

The result I want looks like this:
http://cl.ly/SIBJ

That’s what it looks like right now:
http://cl.ly/SHnf

It would be really nice to get some help on this!

Cheers

Author:  Thomas Hoevel [ Mon Nov 04, 2013 5:54 pm ]
Post subject:  Re: create table and content?

Hi!

VB.Net is not my area of expertise.

Sometimes a picture says more than 1000 words, but I'm afraid your screen shots don't help me understand what you need.

So if you would say how you want to improve what you already have, it would be easier to give you help.

Author:  zuum [ Mon Nov 04, 2013 8:47 pm ]
Post subject:  Re: create table and content?

Thomas Hoevel wrote:
Hi!

VB.Net is not my area of expertise.

Sometimes a picture says more than 1000 words, but I'm afraid your screen shots don't help me understand what you need.

So if you would say how you want to improve what you already have, it would be easier to give you help.


Hey,

I want the header and the table to look like in the first picture.
How can I set the margin of the table and how can I expand it to 100% of the page’s width?

img 1 http://cl.ly/SIlK
img 2 http://cl.ly/SJ87

Author:  Thomas Hoevel [ Tue Nov 05, 2013 9:28 am ]
Post subject:  Re: create table and content?

This is not HTML, you cannot set the table to 100%.

You set the width for each column. Make sure the sum is "100%".
In our application we use a helper routine that creates tables. We specify the width of each column and a flag showing which columns can be adjusted - the table will always have a with of 100% (which will be 16cm, 17cm, or 18cm depending on the page margins).
If you know page size and margins, you may not need such a helper.

You can set the left position of the table. Use table.Rows.LeftIndent.

You should create a style for the header row where you specify font, size, and bold. Create another style for body rows. Assign the correct style to each row.

Author:  zuum [ Tue Nov 05, 2013 9:36 am ]
Post subject:  Re: create table and content?

ok. thanks :)

Page 1 of 1 All times are UTC
Powered by phpBB® Forum Software © phpBB Group
https://www.phpbb.com/