cancel
Showing results for 
Search instead for 
Did you mean: 

To execute Planning Sequence after Report execution

former_member187400
Active Contributor
0 Kudos

Hello All -

I am working in Embedded Planning and AO 2.2.

I have a requirement to run Planning Sequence after Running Variable Selection Screen e.g. 1) Variable Selection screen pop up, 2) Fill up the selection screen, 3) Execute, & report shows data, 4) Planning Sequence is executed automatically. 

What I did is to:

1) To register BADI Callback "After Redisplay", and call Planning Sequence


Public Sub Workbook_SAP_Initialize()

' register callbacks

   Call Application.Run("SAPExecuteCommand", "RegisterCallback", "AfterRedisplay", "Callback_AfterRedisplay")

End Sub

2) To call Planning Sequence


Public Sub Callback_AfterRedisplay()

     Dim lResult As Long

     lResult = Application.Run("SAPExecutePlanningSequence", "PS_1")

End Sub

However, this method never work successfully. Planning Sequence execution always fails.

I used Worksheet_activate. However, this event is not called after Report selection parameter get executed. It's only executed after we deliberately switch from other worksheet, to main worksheet.

I used Workbook_open event, and it cannot run Planning Sequence as well.

The questions:

1) Do you have any thought how we can execute Planning Sequence right after Report execution?

2) How we can make work to run planning sequence in the "After Redisplay" badi?

Kindly please ask your thought, and appreciate your feedback,

Many thanks,

Daniel N.

DoanManhQuynh
Active Contributor
0 Kudos

Hello daniel.nurindra

I know this thread is quite old but Im facing a very same problem; did you find out how to achieve this requirement?

Accepted Solutions (0)

Answers (4)

Answers (4)

former_member187400
Active Contributor
0 Kudos

Hello All - Kindly please ask your thought, and appreciate any thought on this?

Many thanks,

former_member186338
Active Contributor
0 Kudos

Hi Daniel,

Please stop posting same update - it's against forum rules. Looks like nobody have the answer for your question...

Vadim

former_member187400
Active Contributor
0 Kudos

Hi Vadim -

Noted with thanks.

Cheers,

former_member187400
Active Contributor
0 Kudos

Hello All - Kindly please ask your thought, and appreciate any thought on this?

Many thanks,

former_member187400
Active Contributor
0 Kudos

Hello All - Kindly please ask your thought, and appreciate any thought on this?

Many thanks,

former_member187400
Active Contributor
0 Kudos

Appreciate any thought on this?

and Many thanks,