-
Sep 10th, 2021, 08:32 AM
#1
Thread Starter
New Member
-
Sep 13th, 2021, 06:51 AM
#2
Re: Windows Aero Effect in Form
By Aero effect, I am assuming you see the second form sort of 'floating', yes?
Well, not sure if it is possible, BUT, IF THE FORM WAS WHITE, you can make it LOOK like it.
Keep BorderStyle as default (Sizable), set ControlBox to False and Caption to "".
As the top 'border' is shown (although with a smaller height), you can't see the difference if they are both white (at least on MY Win10 machine). (Leave the BackColor of the form to Orange and then change it to White, and you will see what I mean.)
Sam I am (as well as Confused at times).
-
Sep 13th, 2021, 07:50 AM
#3
Re: Windows Aero Effect in Form
Use manifest for your IDE or test your project compiled to EXE w/ manifest.
(I would have tested it myself whether this suggestion fixes anything if there was a project attached to your OP.)
cheers,
</wqw>
-
Sep 13th, 2021, 08:09 AM
#4
Re: Windows Aero Effect in Form
You want it to look like this?
Sam I am (as well as Confused at times).
-
Sep 13th, 2021, 08:25 AM
#5
Thread Starter
New Member
Re: Windows Aero Effect in Form
I was not clear, sorry
I was not talking about the "floating" effect. My question was about the Fade In effect of Aero when the window was opened. That transition is lost when I set BorderStyle = None. I want to keep the fade-in effect, but with the window without a title bar.
Last edited by Walter26; Sep 13th, 2021 at 08:36 AM.
-
Sep 13th, 2021, 11:47 AM
#6
Re: Windows Aero Effect in Form
this was a long time ago, but I remember that u can use different API to play around with the form, to make it transparent, to remove the controlbox dynamically, etc.
I would try:
Declare Function SetLayeredWindowAttributes Lib "user32" (ByVal hwnd As Long, ByVal crKey As Long, ByVal bAlpha As Byte, ByVal dwFlags As Long) As Long
Declare Function GetWindowLong Lib "user32" Alias "GetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long) As Long
Declare Function SetWindowLong Lib "user32" Alias "SetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long
or
Declare Function GetWindowLong Lib "user32" Alias "GetWindowLongW" (ByVal hWnd As Long, ByVal nIndex As Long) As Long
Declare Function SetWindowLong Lib "user32" Alias "SetWindowLongW" (ByVal hWnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long
and look into GWL_STYLE
theres also a "W" version, if u want that. here some const that can be useful
Public Const GWL_STYLE = (-16)
Private Const GWL_EXSTYLE = (-20)
Private Const LWA_ALPHA = &H2
Private Const LWA_COLORKEY = &H1
Private Const WS_CHILD = &H40000000
Private Const WS_POPUP = &H80000000
Private Const WS_EX_LAYERED = &H80000
Private Const WS_CAPTION = &HC00000
Public Const WS_VISIBLE = &H10000000
Private Const SWP_NOACTIVATE As Long = &H10
Private Const SWP_NOSIZE As Long = &H1
Private Const SWP_NOMOVE As Long = &H2
Private Const WS_EX_APPWINDOW As Long = &H40000
Private Const WS_EX_TOOLWINDOW As Long = &H80
Private Const WS_BORDER = &H800000
Private Const WS_DLGFRAME = &H400000
Private Const WS_EX_DLGMODALFRAME = &H1
Private Const WS_EX_CLIENTEDGE = &H200
Private Const WS_EX_STATICEDGE = &H20000
Private Const SWP_FRAMECHANGED = &H20
Private Const SWP_NOZORDER = &H4
Private Const SWP_NOOWNERZORDER = &H200
Private Const GWL_HWNDPARENT = (-8)
Private Const HWND_TOPMOST = -1
Private Const HWND_NOTOPMOST = -2
Private Const AC_SRC_OVER = 0
Private Const AC_SRC_ALPHA = &H1
Last edited by baka; Sep 13th, 2021 at 11:54 AM.
-
Sep 14th, 2021, 06:25 PM
#7
Re: Windows Aero Effect in Form
It seems that the question has to do with the windows fade in effect which I do not think has anything to do with Aero as it was part of Windows before Aero came to be.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|