cancel
Showing results for 
Search instead for 
Did you mean: 

Calling for a database refresh via VBA code

Former Member
0 Kudos

In the previous version of SAP BCP, I had a VBA macro that called for the refresh of data in an excel spreadsheet using the command: Application.Run ("MNU_ETOOLS_REFRESHEET").  Does anyone know how to call this command in SAP EPM? It generates an error.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Aha, I found the answer in a previous post from Vadim Kalinin.  He posted this on June 5, 2013.. and it works in my VBA macro...

"The correct procedure is:

   1.  For the new Excel workbook you have to reference the EPM library:  In the Microsoft Visual Basic for Applications window select menu Tools, then References and then find the list FPMXLClient and check it.

   2. In the procedure code copy the following:

     Option Explicit

    

     Public Sub Refresh_Data()

               Dim EPMObj As New FPMXLClient.EPMAddInAutomation

               EPMObj.RefreshActiveworkbook

End Sub"

Thank you Vadim!

JohnL
Product and Topic Expert
Product and Topic Expert
0 Kudos

Great job searching!

former_member186498
Active Contributor
0 Kudos

Hi Ursula,

then please close the thread assigning "correct answer" to your answer, this will help user with same issue to fiind quickly a solution.

Regards

     Roberto

Answers (0)