Welcome! Log In Create A New Profile

Advanced

WD10: popup window position and table sroll

Posted by PeteM 
PeteM
WD10: popup window position and table sroll
May 27, 2008 01:29PM
Hi All,

I have this code for opening a popup window in relation to a cell:

OpenPopupPosition(JobSelect,poAccordingToControl,COL_Preview_Order)

When table requires horizontal scrolling to get to the column, the popup window is positioned in the top left of the screen, as though the cell position is being read on display (ie not visible on display, so defaults to top-left?), and not being updated on horizontal scrolling.

Has anyone else noticed this, and if so are there any solutions.

Thanks

Pete
Alternatively, is there a way of opening a window/popup in relation to cursor position (ie just below)?

Pete
Carlo Hermus
Re: WD10: popup window position and table sroll
May 27, 2008 06:25PM
Pete,

How about.

Create a window for example MyWindow

In the code of the button or mousclick

Open(MyWindow, MouseXPos(),MouseYPos())

or for popup window

Openpopup(MyWindow, MouseXPos(),MouseYPos())

Set the (popup)window to be not visible

in global procedure

PROCEDURE MYWindow(XPos is int, YPos is int)

In the initialisation procedure

Myself..X = XPos
Myself..Y = YPos
Myself..Visible = True


The not visible setting and Myself..visible is a cosmetic process. When you will not do this, you will see the window in its original position first and then in the position of the mouse. I don't like this, so i set the window to not visible and set it to visible after the new position.

Cheers,
Carlo
PeteM
Thanks Carlo N/T
May 28, 2008 10:23AM
Thanks Carlo,

Regards,

Pete
Author:

Your Email:


Subject:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.
Message: