Showing results for 
Search instead for 
Did you mean: 

How do I modify the system forms with Screen Painter?

Former Member
0 Kudos

Is this even possible? I'm already sick of using the UI API. It requires so much effort for the smallest of changes. Any other recommendations?

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hey Bryan;

I know what you are saying about the API effort and Sorry I don't know the answer to the XML question. However, I thought I would put some remarks on some code I use a lot to put items on forms:

Dim oItem As SAPbouiCOM.Item

Dim oNewItem As SAPbouiCOM.Item

Dim f As SAPbouiCOM.Form

f = SBO_Application.Forms.Item(FormUID) 'Exposed in the SBO_Application_ItemEvent sub and other areas

oItem = f.Items.Item("46") 'Base item number found when system information is shown on form.

oNewItem = f.Items.Add("txtWGHT", SAPbouiCOM.BoFormItemTypes.it_EDIT) 'Create a new edit box.

oNewItem.Left = oItem.Left 'Align Left with Base Item

oNewItem.Width = oItem.Width 'Align Width with Base Item

oNewItem.Top = oItem.Top + oItem.Height 'Put it right below the Base item

oNewItem.Height = oItem.Height

oNewItem.FromPane = 0

oNewItem.ToPane = 0

oNewItem.Enabled = False

oNewItem.RightJustified = True

It uses an existing form element as a base and allows you to quickly add elements. I generally code all that up in a seperate sub in a seperate class and then just call the sub when the form loads and pass it the form. After that you can just treat the new items like all the rest.

I know it's not the answer you are looking for but I thought I would thow it out there in case it could help you.


Former Member
0 Kudos

Hi Bryan...

it is possible...but for which case?

you can save the system form in xml and edit the saved form with the screenpainter...

if you want to edit a system form which you are using in SAP B1(like sales order) please use xml files to add buttons, edittextboxes etc to the system form..


Former Member
0 Kudos

That's what I was guessing, but how do you get the system form into XML to begin with? I tried the export form to xml from the menu, but it doesn't seem to create a file anywhere on my PC. Where is it putting the XML?

Active Contributor
0 Kudos

Hi Bryan,

That export option uses the XML File Folder path as set in General Settings (ie AdministrationSystem Initialisation-General Settings (Path tab). The XML is no use for the screen painter though.

Exporting a system form can be done but I think you'd have to use the UI (ie write a small addon that opens an instance of the form and then uses the GetAsXML method of the Form object to get the XML). You can then load this in to the screen painter for editing.

What you actually want to end up with is just XML for the new controls you are adding. Please see the following thread for details on how to load XML to update system forms:

Kind Regards,