With the function
SetActiveWindow(#Window)
you can make a window active and get it on top of other windows.
Now I'd like to figure out what the layers are. (Which windows is on top and at the back and manage it.)
For a program I'm writing I need to know which one is the least on top. Or set the one least on top.
Is there a comment like SendToBack() or something? And with what syntax?
SendToBack()
SendToBack()
Currently coding the unbelievable WFS program...
You'll know it, when it gets released...
You'll know it, when it gets released...
- netmaestro
- PureBasic Bullfrog

- Posts: 8452
- Joined: Wed Jul 06, 2005 5:42 am
- Location: Fort Nelson, BC, Canada
Re: SendToBack()
On windows:
Code: Select all
SetWindowPos_(hwnd, #HWND_BOTTOM,0,0,0,0,#SWP_NOMOVE|#SWP_NOSIZE)
BERESHEIT
Re: SendToBack()
So I created this code, and expected the calculator window to move to the back, but it didn't.
What am I doing wrong here?
hwnd=0
While hwnd=0
hWnd = FindWindow_(#Null, @"Calculator")
Wend
SetWindowPos_(hWnd, #HWND_BOTTOM,0,0,0,0,#SWP_NOMOVE|#SWP_NOSIZE)
What am I doing wrong here?
hwnd=0
While hwnd=0
hWnd = FindWindow_(#Null, @"Calculator")
Wend
SetWindowPos_(hWnd, #HWND_BOTTOM,0,0,0,0,#SWP_NOMOVE|#SWP_NOSIZE)
Currently coding the unbelievable WFS program...
You'll know it, when it gets released...
You'll know it, when it gets released...
- netmaestro
- PureBasic Bullfrog

- Posts: 8452
- Joined: Wed Jul 06, 2005 5:42 am
- Location: Fort Nelson, BC, Canada
Re: SendToBack()
If it isn't your window, you have to set it to the foreground first. Try this one:
Code: Select all
hwnd=0
While hwnd=0
hWnd = FindWindow_(#Null, "Calculator")
Wend
SetForegroundWindow_(hwnd)
SetWindowPos_(hWnd, #HWND_BOTTOM,0,0,0,0,#SWP_NOMOVE|#SWP_NOSIZE)
BERESHEIT
Re: SendToBack()
Thank you, it works !
Currently coding the unbelievable WFS program...
You'll know it, when it gets released...
You'll know it, when it gets released...
