I have the following code, which sets the position of my window as required:
// POSITION THE WINDOW
Self.Top = 200
Self.left = 0
However - I am now trying to position my window so that the top of my window is 100 pixels up from the bottom of my screen.
Any ideas how to achieve this? Haven’t used Xojo for years and a lot to the code seems to have changed, so now I am struggling with the basics.
Any help appreciated.
Assuming only one screen:
Self.Top = Screen(0).Height - 100
1 Like
Scott_C
(Scott C)
March 6, 2025, 7:18pm
3
Once you determine your Top (and Left), as @Andrew_Lambert suggests, for precise window positioning look into DesktopWindow.Bounds because there can be a difference, depending on your OS and window decorations.
2 Likes
Also a friendly reminder to use the AvailableHeight property to know where you can actually position the Window.
3 Likes