Welcome Guest Search | Active Topics | Sign In | Register

Render HTML tags in Placeholder Options
naman
Posted: Friday, February 15, 2013 6:24:18 AM
Rank: Member
Groups: Member

Joined: 5/22/2012
Posts: 11
Hi ,
I'm trying to create a template pdf with placeholders .So whenever a request comes I can render svg in a that placeholder for that user.
I have made SVG in html , before this i was using directly html to pdf so that was working fine for me. But now I am using template pdf I want to add html to specific placeholder and render that as html not as string.
Is there any way i can do it.??

Thanks in advance,
Naman Ahuja
eo_support
Posted: Friday, February 15, 2013 8:53:57 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,195
naman
Posted: Friday, February 15, 2013 12:33:39 PM
Rank: Member
Groups: Member

Joined: 5/22/2012
Posts: 11
NO...
Basically I have my own placeholder in pdf.I want to add html in that placeholder. As per my assumption it only accepts string.
Any way I can add HTML in that placeholder.

Thanks in advance,
Naman Ahuja
eo_support
Posted: Friday, February 15, 2013 12:41:37 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,195
Hi,

You can't. This is what you can do with our product:

Render HTML into an existing PDF file at any location.

So for example, if you already know your place holder is at page 2 at location (x = 1, y = 1, w = 5, h = 2), then you can use our product to render HTML to that location. If the position is not known, then you should consider using HTML template and have the placeholders inside your HTML template.

Thanks

naman
Posted: Monday, February 18, 2013 7:26:29 AM
Rank: Member
Groups: Member

Joined: 5/22/2012
Posts: 11
Hi,
can you give a small sample code on how can i do this ?
i mean lets say i know the position at which i want to render html, how can i do that ?
a small piece of sample code would be of great help.

Thanks in advance,
Naman Ahuja
eo_support
Posted: Monday, February 18, 2013 10:10:37 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,195
Hi,

You would set the output area by setting HtmlToPdf.Options.OutputArea:

http://www.essentialobjects.com/doc/4/htmltopdf/page_size.aspx

Then call HtmlToPdf.ConvertHtml/ConvertUrl that takes a PdfPage object. For example, you can use this ConvertHtml overload:

http://www.essentialobjects.com/doc/4/eo.pdf.htmltopdf.converthtml_overload_3.aspx

Thanks!
naman
Posted: Monday, February 18, 2013 11:12:26 AM
Rank: Member
Groups: Member

Joined: 5/22/2012
Posts: 11
hi,
thanks for the reply .
One more thing i wanted to know , is there anyway i can find the exact location of block on Pdf,
so that i can calculate the exact position where i want to render my html elements.

Thanks in advance,
Naman Ahuja
eo_support
Posted: Monday, February 18, 2013 12:49:33 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,195
Yes. Please take a look of the HtmlToPdfResult object returned by ConvertHtml/ConvertUrl.

Thanks!
naman
Posted: Thursday, February 21, 2013 12:15:30 PM
Rank: Member
Groups: Member

Joined: 5/22/2012
Posts: 11
Hi ,

Cont. on the same topic,
I am rendering an Image on the page .
After the image is rendered can I write Text on the same image,while i know the x and y position , without using htmltopdf?


Thanks
eo_support
Posted: Thursday, February 21, 2013 12:30:44 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,195
Hi,

Please take a look of the documentation and samples for the "PDF Creator" section.

Thanks
naman
Posted: Thursday, February 21, 2013 12:50:06 PM
Rank: Member
Groups: Member

Joined: 5/22/2012
Posts: 11
hi,
I little specifation will def help.

THANKS
eo_support
Posted: Thursday, February 21, 2013 1:01:37 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,195
Hi,

You will need to read what's already there first. We are happy to guide you towards the solution, but we don't do your work. So you have to put some effort first. Without any effort from your side, we would be basically doing your job. We do not do that. Hope you understand.

Thanks!


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.