 |
|
 |
Can you convert the output of a webpage directly to a PDF document? without having to code it seperately as explained in this article?
Kind of like how in Open Office you can publish directly to PDF?
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
|
 |
|
 |
Can u plz tell me how we can set height and width for the image. Also can u tell me how to fix height and width of cell.
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
 |
Hi
Great dll - but how do you set the tables so that the borders do not show? I've got Border = 0, BorderWidth = 0, Padding = 0, CellPadding = 0 but still the border lines come back to haunt me!
On another point - the control "Table" causes a major conflict with WebControls.Table - perhaps giving another name like "pdfTable" might have helped?
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
 |
Found a way round - but only if the background colour matches!
vTable.BorderColor = iTextSharp.text.Color.WHITE vTable.DefaultCellBorderColor = iTextSharp.text.Color.WHITE
But I'm sure there must be a better method!
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
 |
It's using response.redirect("~\1.pdf").... I want to save the pdf file on button click without directally opening into the browser. Please help me...
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
 |
The code:
Dim doc As Document = New Document PdfWriter.GetInstance(doc, New FileStream(Request.PhysicalApplicationPath + "\1.pdf",FileMode.Create))
creates a new file at the specified location. To store the pdf-file anywhere outside the IIS-directory you could try:
PdfWriter.GetInstance(doc, New FileStream(C:\tmp\1.pdf",FileMode.Create))
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
 |
He, is it possible to make paragraph using this library ? For example to generate a PDF text as follow / xxxxxxxxxxxxxxxx - xxxxxxxxxxxxxxxx . xxxxxxxxxxxxx . xxxxxxxxxxxxxx -
leye
|
| Sign In·View Thread·PermaLink | 1.00/5 (1 vote) |
|
|
|
 |
|
 |
Hello fstrahberger,
This article is great. Thank for your post.
I need little clarification, Is this dll and references from sourceforge.net is licensed or trail.
Whether I can use in my project, It wont show any Privacy or trail or need to buy message in future?
Can you help to clear this doubt.
It is very help full for me.
Thanks in Advance
Senthil.S A Software Engineer
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
|
 |
|
|
 |
|
 |
Try this:
Dim font7 As iTextSharp.text.Font = New iTextSharp.text.Font(iTextSharp.text.Font.HELVETICA, 17) table.AddCell(New Paragraph("blablabla", font7))
|
| Sign In·View Thread·PermaLink | 1.50/5 (2 votes) |
|
|
|
 |
|
 |
Hallo, my page is a table only and has some formviews integrated. 1. when I see the examples I think you can create new tables only and can not use a existing table. am I right or how can I solve the problem? 2. how can I say that the paperformat of the pdf is landscape?
best regards Dietrich
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
 |
Hi,
> I think you can create new tables only I don't know anything about eisting tables, I always created new documents from scratch.
>paperformat of the pdf is landscape
Dim document As Document = New Document(PageSize.LETTER.Rotate)
Regards Florian
|
| Sign In·View Thread·PermaLink | 1.00/5 (1 vote) |
|
|
|
 |
|
 |
Dear fstrahberger
It is really nice Article. The code is in vb.net. I have created the same one for C#.net
How can I send it(or any other samples (image)) to you.
Thank you
sheahad
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
|
 |
|
|
 |
|
 |
Try this conversion tool:
http://www.developerfusion.com/tools/convert/vb-to-csharp/[^]
This generated for me:
public void ShowTable() { Document doc = new Document(); PdfWriter.GetInstance(doc, new FileStream(Request.PhysicalApplicationPath + "\\2.pdf", FileMode.Create)); doc.Open(); Table table = new Table(3); table.BorderWidth = 1; table.BorderColor = new Color(0, 0, 255); table.Padding = 3; table.Spacing = 1; Cell cell = new Cell("header"); cell.Header = true; cell.Colspan = 3; table.AddCell(cell); cell = new Cell("example cell with colspan 1 and rowspan 2"); cell.Rowspan = 2; cell.BorderColor = new Color(255, 0, 0); table.AddCell(cell); table.AddCell("1.1"); table.AddCell("2.1"); table.AddCell("1.2"); table.AddCell("2.2"); table.AddCell("cell test1"); cell = new Cell("big cell"); cell.Rowspan = 2; cell.Colspan = 2; cell.HorizontalAlignment = Element.ALIGN_CENTER; cell.VerticalAlignment = Element.ALIGN_MIDDLE; cell.BackgroundColor = new Color(192, 192, 192); table.AddCell(cell); table.AddCell("cell test2"); doc.Add(table); doc.Close(); Response.Redirect("~/2.pdf"); }
|
| Sign In·View Thread·PermaLink | 2.25/5 (4 votes) |
|
|
|
 |
|
 |
Has anyone got a dll i could use with the AllowPartiallyTrustedCallers attribute. I cant seem to be able to compile it from source with this.
Cheers!
|
| Sign In·View Thread·PermaLink | 4.00/5 (3 votes) |
|
|
|
 |
|
|
 |
|
|
 |
|
 |
One more question: Is it possible to change the font and font properties (size, bold, italics etc)?
TIA, Johnny J.
|
| Sign In·View Thread·PermaLink | 1.00/5 (1 vote) |
|
|
|
 |
|
|
 |
|
 |
Hi,
I got the Security Error when running in the production. I am using ASP.NET to generate PDF file and got the error.
Security Exception Description: The application attempted to perform an operation not allowed by the security policy. To grant this application the required permission please contact your system administrator or change the application's trust level in the configuration file.
Exception Details: System.Security.SecurityException: That assembly does not allow partially trusted callers.
Source Error:
[No relevant source lines]
Source File: App_Web_jyouvtml.0.cs Line: 0
Stack Trace:
[SecurityException: That assembly does not allow partially trusted callers.] test._Default.Page_Load(Object sender, EventArgs e) +0 System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +15 System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +34 System.Web.UI.Control.OnLoad(EventArgs e) +99 System.Web.UI.Control.LoadRecursive() +47 System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +6978 System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +213 System.Web.UI.Page.ProcessRequest() +86 System.Web.UI.Page.ProcessRequestWithNoAssert(HttpContext context) +18 System.Web.UI.Page.ProcessRequest(HttpContext context) +49 ASP.default_aspx.ProcessRequest(HttpContext context) in App_Web_jyouvtml.0.cs System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +303 System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +64
Any help will be appreciable.
Rgds, DEV
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
 |
Take a look at this link: [Recompile dll]
You may have to recompile the dll using: Make sure you have the following in the AssemblyInfo.cs using System.Security; ... [assembly: AllowPartiallyTrustedCallers()]
|
| Sign In·View Thread·PermaLink | 2.00/5 (1 vote) |
|
|
|
 |