cancel
Showing results for 
Search instead for 
Did you mean: 

Form Item Left property

Former Member
0 Kudos

I have added a it_Folder to the item master data form and am now trying to add some user fields to it.

I have no problem until I try to add a field that has a left property greater than 284. I check the ClientWidth and it is set to 947. Once I have added the item, as a test I checked the oNewItem.Left and it is set to 284, but the item comes up on the pane at the far left.

Thanks in advance

Karen

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Karen,

This usually happens, I found no way to put my user items in the exactly place a wanted them, star trying to find the best fit, i think there's no other better way.

hope it helps,

Gabriela.

Former Member
0 Kudos

Hi,

In forms that size can be changed, SBO has 4 areas(Left-Up, Left-Down, Right-Up, Right-Down). Each control is related to one of them, and the position is calculated considering the relative position against the related edge. The problem is that you are giving the position relative to the Top-Up edge. Instead of that, calculate it relative to the related edge:

LeftUpItem.Left = X

LeftUpItem.Top = Y

LeftDownItem.Left = X

LeftDownItem.Top = FormHeight - Y (Y= Num. pixels distance from the edge)

...

RightDownItem.Left = FormWidth - X (X= Num. pixels distance from the edge)

RightDownItem.Top = FormHeight - Y (Y= Num. pixels distance from the edge)

Of course, you have to redefine it each time the form is resized.

Hope helps,

Ibai Peñ

Former Member
0 Kudos

Thanks Ibai, that solved it.

Answers (0)