Error Checking in Excel
Thanks Thanks:  0
Likes Likes:  0
Page 2 of 2 FirstFirst 12
Results 11 to 12 of 12

Thread: Using a Macro as a fuction

  1. #11
    New Member
    Join Date
    Apr 2002
    Posts
    16
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Mark,
    I would like to know how do that anyway, so if you want to help figure that out I would appreciate it.

    Thanks.

  2. #12
    New Member
    Join Date
    Apr 2002
    Posts
    41
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Happy_Dog

    Networkdays does not work unless user has Analysis Toolpak installed. You can overcome this by installing it via code in your workbook.

    To do this use, say, the Open event for the workbook to test whether or not it is installed. If not, install it:

    - Open VBE (Alt+F11)
    - double click ThisWorkbook
    - in the code page, cut and past this

    Private Sub Workbook_Open()
    If AddIns("Analysis toolpak").Installed = False Then AddIns("Analysis toolpak").Installed = True
    End Sub

    Now, each time the workbook is opened it check to see if the toolpak is installed. If it is not, it will install it. This then permits the function to operate.

    Any help?

    Regards

    Robb__

Some videos you may like

User Tag List

Like this thread? Share it with others

Like this thread? Share it with others

Posting Permissions

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