Talk about it!
I'm trying to show a SMS received in a text box on a Form that I have, but instead of showing me the message I receive in my SIM, it shows something such as + CMTI: "ME", 33 . I'll leave the code below:
Imports System
Imports System.Data
Imports System.Data.SqlClient
Imports System.IO.Ports
Imports System.Text
Public Class Form1
Dim inputData As String = ""
Public Event DataReceived As IO.Ports.SerialDataReceivedEventHandler
Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
SerialPort1.PortName = "COM5"
SerialPort1.BaudRate = 9600
SerialPort1.Parity = Parity.None
SerialPort1.DataBits = 0
SerialPort1.StopBits = StopBits.One
SerialPort1.Handshake = Handshake.None
SerialPort1.RtsEnable = True
SerialPort1.Open()
End Sub
Private Sub SerialPort1_DataReceived(sender As Object, e As SerialDataReceivedEventArgs) Handles SerialPort1.DataReceived
inputData = SerialPort1.ReadExisting()
Me.Invoke(New EventHandler(AddressOf DoUpdate))
End Sub
Public Sub DoUpdate()
TextBox1.Text = TextBox1.Text & inputData
End Sub
End Class
Can someone help me with how to show the message in the plain text and not how it is showing?
NOTE: Both PortName and the rest are correct