Is it something like this?
Public Class Form1
Dim int As String
Dim temp As String
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
SerialPort1.Open()
SerialPort1.Write("@nnRUnn00*")
int = SerialPort1.ReadLine()
temp = Mid$(int, 1, 4)
End Sub
End Class