cancel
Showing results for 
Search instead for 
Did you mean: 

raise exception when get ScreenTop of GuiMenu

Former Member
0 Kudos

Hi expert,

When i get ScreenTop property of a GuiMenu object, It raise an exception. Please help me know how can I get GuiMenu ScreenTop and what control i can get this property.

Thanks

Accepted Solutions (0)

Answers (1)

Answers (1)

Christian_Cohrs
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi Thanh,

the GuiMenu does not support this property, even though it is mentioned in the type library. The reason is that the script will access the menu data only, not the rendered window. We will change the behaviour so that you receive a -1 result instead of an exception.

Thanks for reporting the problem.

Best regards,

Christian

Former Member
0 Kudos

Hi Christian,

Not only GuiMemu do no support control location property, there are some controls are the same behavior with GuiMenu control such as Matched code button, Combo Dropdown list, etc. I know the purpose of SAP scripting is support to automatic processing, e-Learning, I'm working on a e-learning system so i need to get control location properties so i can capture control image. Can you tell me SAP Scripting can support some properties as follow in future:

+Can FindByPosition function return the topmost and the leaf control at point, the current FindByPosition function has some problems:

-Do not return the top most control at point. That is I call this function when the mouse

point is pointed to menu control, dropdown list, Matched Code button, it return the

GuiMainWindow.

-Do not return the "leaf control". that is i call it when the mouse point is pointed to tree

control, just return the tree control, does not return the tree node. In menu bar

control, it does not return menu control, just return Menu bar control.

+Can Sap Scripting support control location property to any control that can render on screen.

Best Regards.

Thanh Ngo.

P/S

One more. Can you tell me there is any solution to resolve above problems? thanks a lot.

Christian_Cohrs
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi Thanh,

I'm afraid some of these things will not be feasible, as they are beyond the scope of the API. The main focus of the API is on functional testing, so we do not cover all of the visual effects of SAP GUI. Also, FindByPosition will only find the controls as specified in the API document, but not inner objects of these controls such as tree nodes or Grid cells.

One thing that I'd expect to work is the button for the GuiCTextField controls. If this is not detected correctly then we might be able to fix it.

Best regards,

Christian

Former Member
0 Kudos

Hi Expert,

Thanks for your answer, can you tell me SAP Automation GUI Interfaces is available on what SAP FrontEnd version? With each version, where can I download SAP Automation GUI Interfaces library such as guilib.dll, guilib.lib, guilib.h, etc.

Regards,

Thanh Ngo.

Christian_Cohrs
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi Thanh,

these files are part of guilib and not related to the SAP GUI Scripting API. Guilib is an obsolete automation interface that is no longer supported, as specified in OSS note 398074. Apart from that, I don't know much about guilib

Best regards,

Christian