Skip to Content
avatar image
Former Member

How to get and set Package Links prompt values from EPM Add-in VBA API?

Hey Guys,

It’s my first post here and I would like to introduce myself. My name is Piotr, I’m 29 years old, I live in Warsaw, Poland and work as Junor Consultant.

I was asked by my colleague to help him build cross systems (SAP BPC and Oracle EPM) data load process.

He is the designer of the build and I help him by finding solutions to new problems that occur.

At some point in the data load process we want to:

  • 1)See prompt values assigned to given Package Links
  • 2)Run Package Links with these promts

I have already developed working solution that runs Packages with prompt values stored in Excel sheets, but I would also like to develop similar solution for Package Links. The reason I want to run Package Links is that client has a lot of already defined Package Links.

To achieve it we would like to use Excel EPM Add-in API.

The problem is I don’t know how to see and change Package Links Prompt values in VBA using API.

The Sub DataManagerRunPackageLink (packageLinkId As String, packageLinkName As String) from EPMAddInAutomation only receive package Link ID and package Link name.

I can find package Link ID and prompt values in SAP BPC Database through SAP Client by SE16 -> UJD_LINK -> <ANSWERPROMPT>

but I don’t know how to access BPC Database from EPM Add-in VBA API.

Is it possible?

I also don’t like my current idea. I think it’s over-complicated to extract Package Links prompt values from Database.

Is there any other way to access/change Package Links prompt values from EPM Addin VBA API?



Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

4 Answers

  • Best Answer
    Jun 16, 2017 at 08:35 PM

    After some analysis I can see that package link can't be replaced by multiple DM package launch using VBA - packages in package link are executed one after one depending on results of previous package.

    I can see only one solution - create a new custom logic badi based on the code of program UJD_TEST_PACKAGE_LINK. This badi has to accept answer prompt as a text parameter and will execute package link with this answer prompt.

    Then you can create DM package with script logic running custom logic badi. And you can pass answer prompt for this package using VBA.

    Add comment
    10|10000 characters needed characters exceeded

  • Jun 16, 2017 at 10:56 AM

    Unfortunately there is no way to set package link prompts using VBA EPM. And the idea to directly modify saved prompts in database is bad in general.

    Instead of package links use VBA to set individual prompts for DM packages using modified code of:

    "client has a lot of already defined Package Links" - extract package links from table and write code to run multiple DM packages.

    Add comment
    10|10000 characters needed characters exceeded

  • Jun 16, 2017 at 11:21 AM

    P.S. I can publish the code that can do the following:

    Public Sub TestRunDM()
        Dim strAnsw() As String
        ReDim strAnsw(0 To 5)
        strAnsw(1) = "%DIMENSIONMEMBERS_KEYDATE%V-1"
        strAnsw(5) = "%ADDITIONINFO%V0"
        ExeceuteDM strAnsw, "", "Data Management", "Export Master Data to File", "/CPMB/EXPORT_MD_TO_FILE", "0001"
    End Sub
    Public Sub ExeceuteDM(ByRef strAnswerArr() As String, strTeam As String, strPackageCroup As String, _
        strPackage As String, strChain As String, strUserGroup As String)
    ' strAnswerArr() - each line define a single prompt variable
    ' Line format: %VARIABLENAME%xVALUE
    ' x can be "V" for simple sting value or "P"/"D" for complex string containing dimension names and dimension members
    ' "D" is used for DIMENSIONMEMBER
    ' Single empty line - no answer prompt
    ' strTeam - Team, "" for Company
    ' strPackageCroup - Package Group like "Data Management"
    ' strPackage - Package name like "Clear"
    ' strChain - Process Chain name like "/CPMB/CLEAR"
    ' strUserGroup - User "0001", Admin "0000"
    Add comment
    10|10000 characters needed characters exceeded

  • Jun 16, 2017 at 02:12 PM

    P.P.S. Just published the blog with the ExecuteDM procedure:

    Add comment
    10|10000 characters needed characters exceeded