Q:

Move image from picturebox to another picturebox in another form

im trying to move an image from a PictureBox to another PictureBox in another Form that was captured by a WebCam, but my code is not working. 
Public Class Form12
Private _capture As Emgu. CV.Capture
Private _captureInProgress As Boolean
Dim form23 As Form23

Private Sub btnSave_Click(ByVal sender As System. Object, ByVal e As System. EventArgs) Handles btnSave. Click
    form23.SetPictureBoxImage(captureImageBox. Image)
    form23.Show()
End Sub

Private Sub captureButton_Click(ByVal sender As System. Object, ByVal e As System. EventArgs) Handles captureButton. Click
        If (_capture Is Nothing) Then
            Try
                _capture = New Emgu. CV.Capture
            Catch excpt As NullReferenceException
                MessageBox. Show(excpt. Message)
            End Try
        End If
        If (Not _capture Is Nothing) Then
            If _captureInProgress Then
                Me.captureButton. Text = "Start Capture"
                RemoveHandler Application. Idle, New EventHandler(AddressOf Me. ProcessFrame)

            Else
                captureButton. Text = "Capture"
                AddHandler Application. Idle, New EventHandler(AddressOf Me. ProcessFrame)
            End If
            _captureInProgress = Not _captureInProgress
        End If
End Sub

Private Sub ProcessFrame(ByVal sender As Object, ByVal arg As EventArgs)

    Dim frame As Emgu. CV.Image(Of Emgu. CV.Structure. Bgr, Byte) = Me._capture. QueryFrame
    Dim grayFrame As Emgu. CV.Image(Of Emgu. CV.Structure. Gray, Byte) = frame. Convert(Of Emgu. CV.Structure. Gray, Byte)()
    Dim smoothedGrayFrame As Emgu. CV.Image(Of Emgu. CV.Structure. Gray, Byte) = grayFrame. PyrDown. PyrUp

    captureImageBox. Image = frame. Bitmap
End Sub

Private Sub ReleaseData()
    If (Not _capture Is Nothing) Then
        _capture. Dispose()
    End If
End Sub

2nd Form
Public Class Form23
Public Sub SetPictureBoxImage(ByVal image As Bitmap)
    PictureBox1.Image = image
End Sub
End Class

all the webcam thing is working, just the transfer of image is not.  sorry just a newbie here.  just got this codes from a tutorial. Thanks! 

A:

Forms are classes - it says so at the top of all of them:
Public Class Form817

So, an instance of them should be created and thats is what your code should use everywhere:
Dim myFrm As Form817            ' DECLARES the variable
myFrm = New Form817             ' Initialize myFrm as an instance of Form817

' short method:
Dim myFrm As New Form817

The problem is here:
form23.SetPictureBoxImage(captureImageBox. Image)
form23.Show()

VB is not case sensitive AND your code did not create and instance, so the first line is referencing the class, not the instance.   When you normally do something like Form23.Show - without creating an instance, VB creates one for you with the same name.   This is called the default form instance and should be avoided (always).    
Your image transfer fails because the code references one thing (Form23), but another is shown (a new instance of Form23).