Hi all.
I have UserForm with Picturebox which show part of the screen picture under the mouse.
I want convert my project from VB6 to VB.Net but stuck with fallowing code:
Private Sub Timer1_Tick(ByVal eventSender As System.Object, ByVal eventArgs As System.EventArgs) Handles Timer1.Tick
		Dim ScreenDC As Integer
		Dim lWidth As Integer
		Dim lHeight As Integer
		ScreenDC = GetDC(0)
		' Get and display the current mouse position
		Text1.Text = "X: " & CDbl(CStr(Pt.x)) 
		Text2.Text = "Y: " & CDbl(CStr(Pt.y)) 
		' Block transfer the screen image to picture box
		lWidth = Picture1.ClientRectangle.Width
		lHeight = Picture1.ClientRectangle.Height
		'UPGRADE_ISSUE: Constant vbSrcCopy was not upgraded....
		'UPGRADE_ISSUE: PictureBox property Picture1.hdc was not upgraded....
		Call BitBlt(Picture1.hdc, 0, 0, lWidth, lHeight, ScreenDC, Pt.x - (lWidth / 2), Pt.y - (lHeight / 2), vbSrcCopy)
		'color code
		Text3.Text = VB6.Format(GetPixel(ScreenDC, CInt(CStr(Pt.x)), CInt(CStr(Pt.y))), "### ### ###")
		Call ReleaseDC(0, ScreenDC)
	End Sub
I belive vbSrcCopy conversion i can solve with declaration
Public Const SRCCOPY = &HCC0020

1) But i dont know how to solve problem with Picture1.hdc
(Error 1 'hdc' is not a member of 'System.Windows.Forms.PictureBox'.)
2) second problem with starting Timer
'UPGRADE_WARNING: Add a delegate for AddressOf TimerProc
(Error 3 'AddressOf' expression cannot be converted to 'Integer' because 'Integer' is not a delegate type.)
SetTimer(Me.Handle.ToInt32, TIMER_ID4, 0, AddressOf TimerProc)