#1
  1. No Profile Picture
    Registered User
    ASP Explorer (0 - 99 posts)

    Join Date
    Sep 2004
    Posts
    5
    Rep Power
    0

    appWord Word.Application


    I'm trying to export data fields to a word document, but my code won't compile. I get a compile error: User-defined type not defined at this line of code:

    Dim appWord As Word.Application

    Any ideas? Is there something I need to install or enable? BTW, I'm using Access 2000.
  2. #2
  3. Database junkie..
    ASP Scholar (3000 - 3499 posts)

    Join Date
    May 2004
    Location
    Derry, N Ireland
    Posts
    3,092
    Rep Power
    53
    try this instead

    Dim appword
    Set appword = CreateObject("Word.Application")
    Regards,

    Colm



    If you found a post particularly helpful, show your appreciation by clicking the "scales" icon in the bar just above the post, at the right hand side.
  4. #3
  5. No Profile Picture
    Registered User
    ASP Explorer (0 - 99 posts)

    Join Date
    Jul 2007
    Posts
    1
    Rep Power
    0

    Failed to Create word document object


    I have to dynamically generate a word document using ASP. We are using a word template, and certain values from a database will be inserted in the document.
    However, when i try to create an object of Word, the stmt results in an error saying :

    Set WordApp = CreateObject("word.application")
    *Set WordDoc = WordApp.Documents.Add()

    *Error : "Microsoft Word (0x800A175D) Could not open macro storage."

Similar Threads

  1. Word.Application fail
    By Nyan in forum ASP Development
    Replies: 9
    Last Post: May 7th, 2004, 03:03 AM

IMN logo majestic logo threadwatch logo seochat tools logo