473,396 Members | 1,997 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Strategy for Rendering Multiple Document Types From Single Source

I would appreciate your thoughts and opinions on the following:

I am looking to render documents [that are constructed at runtime] into
multiple document formats. At a minimum the documents will need to be
rendered as HTML, and separately as PDF. Ideally we could also offer a
subset additionally as xls and docx (Excel and/or Word 2007) files.

All files will be distributed via ASP.NET Web site. This is a "greenfield"
project using .NET 3.5, and I can do whatever I want.

It appears to me that there are two general strategies I could take.

1. Render all documents initially as HTML, then to the other document types.

2. Render all documents initially into whatever the final document type will
be (i.e., do not render first as HTML, but just render the pdf file
directly, for example).

Keeping in mind that these files are all built at runtime from information
and templates stored in a database... These templates are basically HTML
snippets styled with css.

My initial preference is for alternative #1 above, as I could have one
single code base that builds these documents at runtime. That single code
base cranks out the HTML version, which is one of the required formats. From
the HTML, it would be a relatively trivial matter to convert the document to
PDF or whatever (there are 3rd party components that could do this
automatically and quickly - perhaps called via some custom HTTP module that
I write).

Thoughts? Opinions?

Thanks!

Jun 27 '08 #1
3 1198
it depends on how complex the documents are. the html to pdf converters
either only do simple html, or use an IE instance and a print driver to
produce pdf.
-- bruce (sqlwork.com)
"Jordan S." wrote:
I would appreciate your thoughts and opinions on the following:

I am looking to render documents [that are constructed at runtime] into
multiple document formats. At a minimum the documents will need to be
rendered as HTML, and separately as PDF. Ideally we could also offer a
subset additionally as xls and docx (Excel and/or Word 2007) files.

All files will be distributed via ASP.NET Web site. This is a "greenfield"
project using .NET 3.5, and I can do whatever I want.

It appears to me that there are two general strategies I could take.

1. Render all documents initially as HTML, then to the other document types.

2. Render all documents initially into whatever the final document type will
be (i.e., do not render first as HTML, but just render the pdf file
directly, for example).

Keeping in mind that these files are all built at runtime from information
and templates stored in a database... These templates are basically HTML
snippets styled with css.

My initial preference is for alternative #1 above, as I could have one
single code base that builds these documents at runtime. That single code
base cranks out the HTML version, which is one of the required formats. From
the HTML, it would be a relatively trivial matter to convert the document to
PDF or whatever (there are 3rd party components that could do this
automatically and quickly - perhaps called via some custom HTTP module that
I write).

Thoughts? Opinions?

Thanks!

Jun 27 '08 #2
Some documents are short and trivial, but others complex and lengthy. In
either case I was hoping to leverage the styling (font properties, image
layout etc) that are already appled to the HTML so that I don't have to
duplicate that logic for each rendered file type.

-J
"bruce barker" <br*********@discussions.microsoft.comwrote in message
news:EA**********************************@microsof t.com...
it depends on how complex the documents are. the html to pdf converters
either only do simple html, or use an IE instance and a print driver to
produce pdf.
-- bruce (sqlwork.com)
"Jordan S." wrote:
>I would appreciate your thoughts and opinions on the following:

I am looking to render documents [that are constructed at runtime] into
multiple document formats. At a minimum the documents will need to be
rendered as HTML, and separately as PDF. Ideally we could also offer a
subset additionally as xls and docx (Excel and/or Word 2007) files.

All files will be distributed via ASP.NET Web site. This is a
"greenfield"
project using .NET 3.5, and I can do whatever I want.

It appears to me that there are two general strategies I could take.

1. Render all documents initially as HTML, then to the other document
types.

2. Render all documents initially into whatever the final document type
will
be (i.e., do not render first as HTML, but just render the pdf file
directly, for example).

Keeping in mind that these files are all built at runtime from
information
and templates stored in a database... These templates are basically HTML
snippets styled with css.

My initial preference is for alternative #1 above, as I could have one
single code base that builds these documents at runtime. That single code
base cranks out the HTML version, which is one of the required formats.
From
the HTML, it would be a relatively trivial matter to convert the document
to
PDF or whatever (there are 3rd party components that could do this
automatically and quickly - perhaps called via some custom HTTP module
that
I write).

Thoughts? Opinions?

Thanks!



Jun 27 '08 #3
I would look to create one type of document using code, and then find
something that can convert that document type into other formats on demand.
Simplify your problem, find something to solve your most complex issue, and
then solve the other formats.

Regards

John Timney (MVP)
http://www.johntimney.com
http://www.johntimney.com/blog
"Jordan S." <A@B.comwrote in message
news:%2****************@TK2MSFTNGP06.phx.gbl...
Some documents are short and trivial, but others complex and lengthy. In
either case I was hoping to leverage the styling (font properties, image
layout etc) that are already appled to the HTML so that I don't have to
duplicate that logic for each rendered file type.

-J
"bruce barker" <br*********@discussions.microsoft.comwrote in message
news:EA**********************************@microsof t.com...
>it depends on how complex the documents are. the html to pdf converters
either only do simple html, or use an IE instance and a print driver to
produce pdf.
-- bruce (sqlwork.com)
"Jordan S." wrote:
>>I would appreciate your thoughts and opinions on the following:

I am looking to render documents [that are constructed at runtime] into
multiple document formats. At a minimum the documents will need to be
rendered as HTML, and separately as PDF. Ideally we could also offer a
subset additionally as xls and docx (Excel and/or Word 2007) files.

All files will be distributed via ASP.NET Web site. This is a
"greenfield"
project using .NET 3.5, and I can do whatever I want.

It appears to me that there are two general strategies I could take.

1. Render all documents initially as HTML, then to the other document
types.

2. Render all documents initially into whatever the final document type
will
be (i.e., do not render first as HTML, but just render the pdf file
directly, for example).

Keeping in mind that these files are all built at runtime from
information
and templates stored in a database... These templates are basically HTML
snippets styled with css.

My initial preference is for alternative #1 above, as I could have one
single code base that builds these documents at runtime. That single
code
base cranks out the HTML version, which is one of the required formats.
From
the HTML, it would be a relatively trivial matter to convert the
document to
PDF or whatever (there are 3rd party components that could do this
automatically and quickly - perhaps called via some custom HTTP module
that
I write).

Thoughts? Opinions?

Thanks!




Jun 27 '08 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Hamed | last post by:
Hello Every where in .NET books is mentioned that VS.NET is a seamless cross platform environment. We have two groups of programmers that some are VB programmer but others prefer to use C#. Is it...
5
by: Dave A | last post by:
I am writing an ASP.NET tool that will allow the client to create their own online froms. ie the client can add tect boxes, text, drop downs,etc with absolutely no technical skill what so ever....
12
by: Dabbler | last post by:
I need to insure that at least one of three phone number fields has a value (requiredfield) but I'm not sure of a way to implement this without server side logic. Is there a way to use the...
3
by: Jordan S. | last post by:
I would appreciate your thoughts and opinions on the following: I am looking to render documents into multiple document formats. At a minimum the documents will need to be rendered as HTML, and...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.