Showing results for 
Search instead for 
Did you mean: 

UI API Add-on disconnected

Former Member
0 Kudos

Hi all,

I'm making an UI API Add-on that hides the right click menu on the marketing document form.

The add-on works at the first time, but after the first execution, it is disconnected, and the system message that the add-on is disconnected appear, with the options to "Restart add-on", "Log off" and "Continue without the add-on".  

So, I want to know how to avoid this message and keep the add-on connected.

This is my code:

objGUIAPI = new SAPbouiCOM.SboGuiApi();


objApp = objGUIAPI.GetApplication(-1);

objApp.RightClickEvent += new SAPbouiCOM._IApplicationEvents_RightClickEventEventHandler(objApp_RightClickEvent);


static private void objApp_RightClickEvent(ref SAPbouiCOM.ContextMenuInfo eventInfo, out bool BubbleEvent)


            BubbleEvent = true;




Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

After some tests, I could resolve the problema.

Just adding " [STAThread]" at the start of the class, resolved the problem.

Answers (0)