Jump to content

Table rotated cell content


Recommended Posts

I cannot figure out how to make the content in the table cell rotate 90degrees. I added the line:

myTable.Rows[0].Cells[0].Rotate = 90;

and nothing rotates.




var myTable = new FPTable;

myTable.AddColumns(7200, 7200, 7200, 7200);


myTable.Rows[0].Cells[0].Margins = new FPTableMargins;


myTable.Rows[0].Cells[0].Font="Times New Roman";


myTable.Rows[0].Cells[0].SetBorders("Thin", "Black", "Top", "Bottom", "Right", "Left");

myTable.Rows[0].Cells[0].Rotate = 90;

myTable.Rows[0].CopyCells(0, 1,2,3);


myTable.Rows[0].Cells[0].Content = "Header1";

myTable.Rows[0].Cells[1].Content = "Header2";

myTable.Rows[0].Cells[2].Content = "Header3";

myTable.Rows[0].Cells[3].Content = "Header4";





return myTable.MakeTags();

Link to comment
Share on other sites

First of all, the property is "Rotation", not "Rotate".

myTable.Rows[0].Cells[0].Rotation = 90;

Also, this line is bogus:

myTable.Rows[0].Cells[0].Margins = new FPTableMargins;

Unless you actually set something in that Margins, like Top, Left, etc. You can set them all at once if you want, like so:

myTable.Rows[0].Cells[0].Margins = {Top:60, Bottom:40, Left:600, Right:600};

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...