More help on ASP and Word

Results 1 to 2 of 2

Thread: More help on ASP and Word

  1. #1
    Fion Guest

    Default More help on ASP and Word

    I desperate for substantial help in getting Asp form values into a Word template and printing them out.I need to develop a program that inserts values captured in an ASP form to a predefined Word template with a standard header and footer. This template is very similar to an order form, whereby values captured in the ASP form are item description, item quantity and price. I need to insert these values into their appropriate place in the Word template and invoke a print command to print out the full order.<BR><BR>How do I establish a relationship/connection between these two?(ie create an object or something?)<BR>before I can proceed to the actual implemetation of inserting the form values into the template?<BR><BR>All help will be deeply appreciated.<BR>Thanks.<BR><BR>Fion<BR><BR>

  2. #2
    jblome Guest

    Default RE: More help on ASP and Word

    I did something rather similar with excel, perhaps you could modify the code for word. I open up the template file:"template.xls" and modify its contents. Here is a piece of my code:<BR><BR>Set xlApplication = Server.CreateObject("Excel.Application")<BR>xlAppl ication.Workbooks.Close<BR>xlApplication.Workbooks .Open "D:Template.xls"<BR>Set xlWorksheet = xlApplication.Worksheets(1)<BR>xlWorksheet.Cells(5 3,6) = objRec("PlanningI")<BR>...UpdateInfo<BR>xlWorkshee t.SaveAs Server.MapPath(".") & "month" & ".xls"<BR>xlApplication.Quit <BR>Set xlWorksheet = Nothing<BR>Set xlApplication = Nothing<BR><BR>I would assume that the open and save information would be the same with the application info inserted. <BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts