Hello All,
I'm using AO 2.2.
My workbook owns:
1 Bex query : DS_1
4 Bex queries Input- ready : DS_2, DS_3, DS_4, DS_5
When I open my workbook I would like to refresh data for DS_1, and DS_2. But DS_3, DS_4, DS_5 have not been executed because a value I have to select a value in DS_1 result to execute other queries.
For DS_2, DS_3, DS_4, DS_5 I have to check option "Planning : Open Data Source Input-Enabled" into planning ribon.
And
Public Sub Workbook_SAP_Initialize() Application.ScreenUpdating = False Dim lResult As Long lResult = Application.Run("SAPExecuteCommand", "Refresh", "DS_1;DS_2")
lResult = Application.Run("SAPExecuteCommand", "RegisterCallback", "AfterRedisplay", "Callback_AfterRedisplay") | |
lResult = Application.Run("SAPExecuteCommand", "RegisterCallback", "BeforePlanDataReset", "Callback_BeforePlanDataReset") Application.ScreenUpdating = True EndSub |
Result:
DS_3, DS_4, DS_5 are executed : a lock is generated in BW with wrong value due to the input-ready functionality.
Expecting value:
DS_3, DS_4, DS_5 are not executed. No lock is generated.
I've tried to add lResult = Application.Run("SAPExecuteCommand", "PlanDataToDisplayMode", "DS_3;DS_4;DS_5"), but nothing is changed.
Is existing a solution to avoid Datasource initialization (ie. Bex query execution) when the workbook is opened ? And how to start the initiatization of DS after ?
Thanks a lot for your help.
Sebastien