Quantcast
Channel: VBForums - Visual Basic .NET
Viewing all articles
Browse latest Browse all 27230

how to create a program that receives messages using at commands in vb 2010?

$
0
0
hey guys i really need some help.

i tried this codes below that i created but it cant receive messages. and if it can i like to read it directly in Richtextbox.

here is the code:

Public Sub receive()
If srPort.IsOpen = True Then
Try

With srPort
.WriteLine("AT")
.WriteLine("AT+CMGF=1" & Chr(34) & vbCrLf)
.WriteLine("AT+CSCS=""PCCP437""" & Chr(34) & vbCrLf)
.WriteLine("AT+CPMS=""SM""" & Chr(34) & vbCrLf)
.WriteLine("AT+CMGL=""REC UNREAD""" & receiveRT.Text & vbCrLf)


End With
Catch ex As Exception

End Try

End If
End Sub

Viewing all articles
Browse latest Browse all 27230

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>