Skip to Content

How to access programatically "System messages log" below the sap b1 window ?

Jan 05, 2017 at 04:48 PM


avatar image

Hi everyone,

If I use option "System Information" that allows me to see what form I currently hover with mouse I may observe that the "System messages log" have form uid = 683 (as at the picture attached).

Then I would like to know what height it has. For this I am using the code as below:

Form messageLogForm = Core.Connection.ConnectionHolder.Application.Forms.Item("683") as Form;
var height = messageLogForm.Height;


var height = Core.Connection.ConnectionHolder.Application.Forms.Item("10000020L").Height;

Core.Connection.ConnectoinHolder is my own class which is representing connection of my addon written in C# and SAP B1, current instance. Suppose "Core.Connection.ConnectionHolder.Application " is normal Application Object in SAP UI API.

The problem which I have is the error I am receiving whenever I would like to access this form object. Is that some special way to do so or somewhere is my mistake involved ? My main aim is to get to know how height is this system messages log tab at below the form.

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

2 Answers

Best Answer
DIEGO LOTHER Jan 05, 2017 at 07:44 PM

Hi Dariusz,

For use the Forms.Item method you need know the formUID of form the message log form. Then I suggest you to use the Forms.GetForm method when supplying a type and instance count.

Dim messageLogForm As Form = Core.Connection.ConnectionHolder.Application.Forms.GetForm("683", 0)
Dim height = messageLogForm.Height

For the second parameter I believe that is not possible to open more than one message log form, so you can use 0. But if the message log form is closed, when you execute the line above, you will receive an exception.

Kind Regards,

Diego Lother

10 |10000 characters needed characters left characters exceeded
Dariusz Gaweł Jan 09, 2017 at 04:59 PM

Hi Diego,

works well.
Thank you for your suggestion.

Show 1 Share
10 |10000 characters needed characters left characters exceeded

Hi Dariusz,


Don't forget to click on the accept button below my answer.

Kind Regards,

Diego Lother