cancel
Showing results for 
Search instead for 
Did you mean: 

Default form

Former Member
0 Kudos
43

Hi all,

How to call default form by clicking any menu which created newly.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Sudarsan,

First of all you need to catch the menu event fired by SBO Application object in your startup class. Try putting in the following code

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

If pVal.BeforeAction = False Then

Case "mnu_ABC"

Dim oXMlDoc As Xml.XmlDocument

oXMlDoc = New Xml.XmlDocument

Dim sPath As String

sPath = "C:\Program Files\SAP\Addnos"

oXMlDoc.Load(sPath & "\" & "MyForm.xml")

Return oXMlDoc.InnerXml

End Select

End If

End Sub

Hope it works out. Also try looking for previouse threads regarding the same by using the search box on top of the page.

Regards

Rizwan Hafeez

Team Lead

SAP Addon Development Section

Abacus Consulting - Pakistan

Answers (0)