Generating Word document from information in Database

Discussion in 'ASP .Net' started by =?Utf-8?B?Tm92aWNl?=, Jun 9, 2004.

  1. Hi all, I'm a novice VB.NET and VBA programmer and am wondering if there is a tutorial out there on how to create a word document based on data in a database and then return that document to a web user. I'm using Visual Studio .Net 2003 for my IDE

    I am familiar enough with VBA to be able to write all the code to generate the document, it is just that I'm not certain how to create the word document in memory and not have Office pop-up on the server. So my first question is
    1. What code do I write in VB (and what imports do I use) such that office doesn't pop-up on the server

    I'm also wondering whether I should just do the following

    Response.ContentType = "application/msword
    and then just iterate over the word document line by line and do a
    Response.Write(
    for each line of the documen

    or whether I should actually generate the file on the server and cache it in the file system and then redirect the user to the location of that file on the server. So my second question is
    2. Should I write the response directly to the output stream or should I cache the file and redirect the user

    I suppose question 2 really depends on how static the content is and whether there is any value in caching the data - in all likelyhood there would be no real value in caching it since it changes so ofte

    Lastly, I also have to look into generating PDF's - for now I suppose I can do a binding using Crystal Reports to generate them

    Thanks
    Novice
    =?Utf-8?B?Tm92aWNl?=, Jun 9, 2004
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Vimal
    Replies:
    0
    Views:
    486
    Vimal
    Oct 14, 2004
  2. Replies:
    13
    Views:
    557
    Mark Rae
    Apr 12, 2007
  3. srk
    Replies:
    0
    Views:
    624
  4. srk
    Replies:
    0
    Views:
    597
  5. Replies:
    9
    Views:
    380
    Martin CLAVREUIL
    Sep 23, 2007
Loading...

Share This Page