|
-
Jun 16th, 2005, 12:57 PM
#1
Thread Starter
Admodistrator
Help convert to .net
VB Code:
Private type RECT
Left As Long
Top As Long
Right As Long
Bottom As Long
End Structure
Sub PositionForm()
Dim WindowRect As RECT
SystemParametersInfo(SPI_GETWORKAREA, 0, WindowRect, 0)
Me.Top = WindowRect.Bottom * Screen.TwipsPerPixelY - Form1.Height
Me.Left = WindowRect.Right * Screen.TwipsPerPixelX - Form1.Width
End Sub
this will place the form above the taskbar, but it gives out a ton of errors. Does anyone know?
-
Jun 16th, 2005, 01:05 PM
#2
Frenzied Member
Re: Help convert to .net
one thing i notice is your RECT. It should be like this:
VB Code:
Private STRUCTURE RECT
DIM ....
DIM....
DIM...
End STRUCTURE
-
Jun 16th, 2005, 01:08 PM
#3
Member
Re: Help convert to .net
Instantiate a graphics object, then do a graphics.drawrectangle( pen, x, y, width, height)
import system.drawing first
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
|