powerpivot macro

RobertCotton

Board Regular
Joined
Nov 1, 2010
Messages
99
I've seen lots of posts from people (myself included) asking how to keep the powerpivot addin "permanently" loaded with no real definitive answer.

Has anyone given any thought to creating a macro that could be run to load the powerpivot addin? Would that even be possilbe? I've written lots of macros but I wouldn't even have a clue where to begin but my experience has always been that there are a lot of very smart people on this site.

A big part of why I ask is that I would like to be able to distrubute powerpivot reports to my boss and others who are not too impressed when I suggest the have to go to options, addins, com addins, etc. every time they open excel.

Any thoughts or suggestions would be greatly appreciated.

Thanks
Robert
 

Excel Facts

Who is Mr Spreadsheet?
Author John Walkenbach was Mr Spreadsheet until his retirement in June 2019.
This should cater for 2010 and 2013:
Code:
Sub LoadPowerPivot()
   On Error Resume Next
   Select Case CLng(Application.Version)
      Case 14
         Application.COMAddIns("Microsoft.AnalysisServices.Modeler.FieldList").Connect = True
      Case 15
         Application.COMAddIns("PowerPivotExcelClientAddIn.NativeEntry.1").Connect = True
      Case Else
   End Select
   If Err.Number <> 0 Then MsgBox "Error loading PowerPivot - please make sure it is installed"
End Sub
 
Upvote 0

Forum statistics

Threads
1,223,958
Messages
6,175,628
Members
452,661
Latest member
Nonhle

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top