Skip to Content
0
Former Member
Mar 26, 2010 at 07:11 AM

Problem Positioning Check box on Folder

36 Views

Hi All,

I am really pulling my hair out trying to position a text box on the screen.

I have added a new folder on the service call screen. This folder's pane level is set to 8. Now I want to add a check box onto that folder. I get the position of another item on the screen (let's say the Origin combo box on the first folder) and then I set my new item's top position to the same position as the Origin combo box. My code:

                        aItem = oForm.Items.Item("67") 'Origin Combo Box
                        oItem = oForm.Items.Add("chk_Refr", SAPbouiCOM.BoFormItemTypes.it_CHECK_BOX)
                        oItem.Left = 10
                        oItem.Top = aItem.Top
                        oItem.FromPane = 8
                        oItem.ToPane = 8
                        oCheck = oItem.Specific
                        oCheck.Caption = "Refrigeration"

This code does not put it in the same top position as the Origin Combo box, but almost half way down the screen. I have tried various other top values. I have started at 10, which puts it right at the top of the screen, I go down to about 180 which puts it just above the row of folders.

BUT it seems like as soon as I move it onto the folder, at let's say Top = 200, it moves it down to 200 from the top of the folder! So it's way down. The difference from Top = 180 to Top = 200 is about 10cm (4 inches) on my screen?????

It does the same even if I remove the FromPane and ToPane property setting.

Any ideas?

Also, I have a matrix on another tab that I also added, which I set to the same top position and that works great, no problem. Seems like it's only with the check box?

Thanks for any help in advance,

Adele