iTextsharp, PdfPCell.VerticalAlignment and PdfPCell.HorizontalAlignment
问题 Im trying to figure out how to get my text inside a PdfPCell to show in the middle. I have tried many different options, like: myCell.VerticalAlignment = Element.ALIGN_MIDDLE; myCell.VerticalAlignment = PdfPCell.ALIGN_MIDDLE; myCell.VerticalAlignment = Rectangle.ALIGN_MIDDLE; None of that works for me. VerticalAlignment takes an int, so I tried to make a loop, to see if i could find the right number, but everything just get left bottom align.. Document myDocument = new Document(PageSize.A4);