I need to allign a secondary form to the right border of other form.
When we compile and run a COMPILED application (not when running it from the IDE) with AERO enabled, this is what happens:
So thanks to the great asnwer of GJKH here : How to determine correctly the Non-Client Area Size for Aero?
...Now I can allign the secondary form to the right of the main form, But the secondary form stills unaligned a bit of pixels from the top:
This is the code I'm using:
If Debugger.IsAttached Then
Form2.Location = New Point(Me.Right, Me.Top)
Else
Form2.Location = New Point((Me.Location.X + (Me.Width + (Me.Width - Me.ClientSize.Width))), Me.Location.Y)
End If