cancel
Showing results for 
Search instead for 
Did you mean: 

Copy system forms ?

Former Member
0 Kudos

Is their any way to copy system forms (only UI) and customise to create new forms ?

For ex, I would like a form similar to the look and feel of the sales order. Therefore, I would like to copy the UI and change it to my need and code its funtionality.

Please advice.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Dear Gautam Ganguly:

suppose that you have opened the Sales Orders Form

Solution 1:

-


Private WithEvents SBO_Application As SAPbouiCOM.Application

Dim oFormParams As SAPbouiCOM.IFormCreationParams

Dim oForm As SAPbouiCOM.IForm

Dim oTestForm As SAPbouiCOM.IForm

Dim oXmlDoc As Xml.XmlDocument

oForm = SBO_Application.Forms.GetForm("139", 1)

oString = oForm.GetAsXML()

oFormParams = SBO_Application.CreateObject(SAPbouiCOM.BoCreatableObjectType.cot_FormCreationParams)

oFormParams.BorderStyle = SAPbouiCOM.BoFormBorderStyle.fbs_Fixed

oFormParams.FormType = "testForm"

oFormParams.UniqueID = "testForm"

oFormParams.XmlData = oString

oTestForm = SBO_Application.Forms.AddEx(oFormParams)

-


Solution 2:

-


oForm = SBO_Application.Forms.GetForm("20700", 1)

oString = oForm.GetAsXML()

' here you have to close Sale Order Form, or you can change your oString with another different

' form UID, otherwise, when load batch action, form existing error will display

oXmlDoc = New Xml.XmlDocument

oXmlDoc.LoadXml(oString)

SBO_Application.LoadBatchActions(oXmlDoc.InnerXml)

-


Thanks

Warren

Answers (0)