Hi Analysis Office VBA programmers,
are your tired of looking up Analysis Office VBA command syntax in the documentation?
are you jealous of the great context sensitive help in Design Studio while writing code there?
If you answer at least one of those questions with yes it will be worth reading that blog.
In this first part of my series I will explain how to get a generic syntax help while coding analysis specific vba like that...
list of available commands |
---|
![]() |
To get this help you need to follow these steps:
- Go to the VBA editor and create a new Module.
- Paste in the following code which can be used as example implementation
Public Function SAP_SetFilter(iDataSource As String, iDimension As String, iMember As String, iMemberFormat As String) As Integer SAP_SetFilter = Application.Run("SAPSetFilter", iDataSource, iDimension, iMember, iMemberFormat) End Function Public Function SAP_AddMessage(iText As String, Optional iSeverity As String = "INFORMATION", Optional iDetails As String = "") As Integer SAP_AddMessage = Application.Run("SAPAddMessage", iText, iSeverity, iDetails) End Function
- Export your Module to a .bas file
When you do your next VBA project simply import your .bas file in the vba editor and as soon as you write your vba code you can see the help available like on the screens above.
In the next part of that blog I will explain how to enrich that with more details like the available filter setting for the SAPSetFilter command like on the screen below.
Hope you enjoy...
Dirk
PS: Maybe we will find someone who has some spare time to generate a complete list. I will not find the time myself in the next weeks and I do not have a full list up to now.