is it possible to move the picturebox inside a panel in vb windows form?

if yes can i know what is the code?
thx and i appreciate ur help :)

You can set the position by

PictureBox1.Location = New Point(xpos,ypos)
Dim x As Integer
Dim y As Integer

Private Sub PictureBox1_MouseDown(ByVal sender As System.Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles PictureBox1.MouseDown
    x = e.X
    y = e.Y
End Sub

 Private Sub PictureBox1_MouseMove(ByVal sender As System.Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles PictureBox1.MouseMove
    If e.Button = Windows.Forms.MouseButtons.Left Then
        PictureBox1.Left -= (x - e.X)
    End If
End Sub
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.