Results 1 to 2 of 2
  1. #1
    3 Star Lounger
    Join Date
    Aug 2002
    Location
    Denmark
    Posts
    347
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Setting references programmatically... (WinXP/O2003)

    Hi,

    I've created a little tool that applies a standard format to my tables...(provided various optional business rules)

    Now wondering if I can set a reference programmatically to it from another menu I have.
    Right now I can't get it to work, gets error message "Invalid use of property" when I try this on the Workbook_Open event at the "ThisWorkbook" object
    Code line is: "ThisWorkbook.VBProject.References strPath_AddIns & strFile_Tableformatter"

    Any clues on why this doesn't work...??

    Thanks,
    Bests,
    RD


    PS: Wish there were a knob on the TV to turn up the intelligence. There's a knob called "brightness," but that doesn't work

  2. #2
    Platinum Lounger
    Join Date
    Feb 2001
    Location
    Weert, Limburg, Netherlands
    Posts
    4,812
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Setting references programmatically... (WinXP/O2003)

    I suspect you need:

    ThisWorkbook.VBProject.References.AddFromFile strPath_AddIns & strFile_Tableformatter
    Jan Karel Pieterse
    Microsoft Excel MVP, WMVP
    www.jkp-ads.com
    Professional Office Developers Association

Posting Permissions

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