Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

What event trigger the cancel document?

May I know what event can I use to check if user cancel the document?

I need to update some table status when user right click the Purchase Order to cancel the document.

Tags:
Former Member
Former Member replied

hi.

Can u plz try this code under menu click event...

  Private Sub SBO_Application_MenuEvent(ByRef pVal As SAPbouiCOM.MenuEvent, ByRef BubbleEvent As Boolean) Handles SBO_Application.MenuEvent

        Try

            If pVal.BeforeAction = True Then

                Select Case pVal.MenuUID

                    Case "1284"

                        oForm = SBO_Application.Forms.ActiveForm

                        If (oForm.TypeEx = "142") Then

                            SBO_Application.SetStatusBarMessage("You Dont have the Permission to Cancel the Document...", SAPbouiCOM.BoMessageTime.bmt_Short, True)

                            BubbleEvent = False

                        End If

                End Select

            End If

        Catch ex As Exception

            SBO_Application.MessageBox(ex.Message)

        End Try

end sub

1 View this answer in context
Not what you were looking for? View more on this topic or Ask a question