Click here to Skip to main content
15,917,005 members
Home / Discussions / Visual Basic
   

Visual Basic

 
AnswerRe: How to add 3 IF conditions at VB Pin
Richard MacCutchan10-Mar-19 22:55
mveRichard MacCutchan10-Mar-19 22:55 
GeneralRe: How to add 3 IF conditions at VB Pin
RedPandinus10-Mar-19 23:07
RedPandinus10-Mar-19 23:07 
GeneralRe: How to add 3 IF conditions at VB Pin
Richard MacCutchan10-Mar-19 23:38
mveRichard MacCutchan10-Mar-19 23:38 
SuggestionRe: How to add 3 IF conditions at VB Pin
Richard Deeming11-Mar-19 9:29
mveRichard Deeming11-Mar-19 9:29 
GeneralRe: How to add 3 IF conditions at VB Pin
Mycroft Holmes11-Mar-19 11:39
professionalMycroft Holmes11-Mar-19 11:39 
GeneralRe: How to add 3 IF conditions at VB Pin
Richard MacCutchan11-Mar-19 22:15
mveRichard MacCutchan11-Mar-19 22:15 
GeneralRe: How to add 3 IF conditions at VB Pin
Richard MacCutchan11-Mar-19 22:16
mveRichard MacCutchan11-Mar-19 22:16 
QuestionRead a messages in vb.net, itry to create a script that can read a sms if someone reply to your text via gsm modem. Pin
jhane Harvest9-Mar-19 19:32
jhane Harvest9-Mar-19 19:32 
Here is my code:

Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click
AddHandler send_sms.SerialPort.DataReceived, New SerialDataReceivedEventHandler(AddressOf DataReceived)
Try
With send_sms.SerialPort

rcvdata = ""
send_sms.SerialPort.WriteLine("AT" & vbCrLf) 'is modem okay?
Thread.Sleep(1000)

send_sms.SerialPort.WriteLine("AT+CMGF=1" & vbCrLf) 'To format SMS as a TEXT message
Thread.Sleep(1000)

send_sms.SerialPort.WriteLine("AT+CPMS=""SM""" & vbCrLf) ' Select SIM storage
Threading.Thread.Sleep(1000)

send_sms.SerialPort.WriteLine("AT+CMGL=""REC UNREAD""" & vbCrLf) 'read unread messages
Threading.Thread.Sleep(1000)

send_sms.SerialPort.WriteLine("AT+CMGL=""ALL""" & vbCrLf) 'print all message
Threading.Thread.Sleep(1000)


RichTextBox1.Text = send_sms.SerialPort.ReadBufferSize()

RichTextBox1.Text = send_sms.SerialPort.ReadLine()
' send_sms.SerialPort.ReadLine = RichTextBox1.ToString()
'MsgBox(rcvdata.ToString)

End With


Catch ex As Exception
MsgBox(ex.Message)
End Try

End Sub
Private Sub test(ByVal indata As String)
rcvdata &= indata

End Sub

__ it only read the status of port says "OK"
please, help me.
SuggestionRe: Read a messages in vb.net, itry to create a script that can read a sms if someone reply to your text via gsm modem. Pin
Richard MacCutchan9-Mar-19 21:50
mveRichard MacCutchan9-Mar-19 21:50 
SuggestionRe: Read a messages in vb.net, itry to create a script that can read a sms if someone reply to your text via gsm modem. Pin
Ralf Meier10-Mar-19 22:13
mveRalf Meier10-Mar-19 22:13 
GeneralRe: Read a messages in vb.net, itry to create a script that can read a sms if someone reply to your text via gsm modem. Pin
jhane Harvest10-Mar-19 22:28
jhane Harvest10-Mar-19 22:28 
SuggestionRe: Read a messages in vb.net, itry to create a script that can read a sms if someone reply to your text via gsm modem. Pin
Ralf Meier11-Mar-19 1:17
mveRalf Meier11-Mar-19 1:17 
GeneralRe: Read a messages in vb.net, itry to create a script that can read a sms if someone reply to your text via gsm modem. Pin
jhane Harvest11-Mar-19 14:46
jhane Harvest11-Mar-19 14:46 
QuestionSyntax Error (Missing Operation) in query expression Pin
RedPandinus9-Mar-19 5:47
RedPandinus9-Mar-19 5:47 
AnswerRe: Syntax Error (Missing Operation) in query expression Pin
Gerry Schmitz9-Mar-19 11:02
mveGerry Schmitz9-Mar-19 11:02 
GeneralRe: Syntax Error (Missing Operation) in query expression Pin
RedPandinus9-Mar-19 11:11
RedPandinus9-Mar-19 11:11 
GeneralRe: Syntax Error (Missing Operation) in query expression Pin
Mycroft Holmes9-Mar-19 11:40
professionalMycroft Holmes9-Mar-19 11:40 
AnswerRe: Syntax Error (Missing Operation) in query expression Pin
Richard Deeming11-Mar-19 9:27
mveRichard Deeming11-Mar-19 9:27 
AnswerRe: Syntax Error (Missing Operation) in query expression Pin
Mycroft Holmes11-Mar-19 11:37
professionalMycroft Holmes11-Mar-19 11:37 
GeneralRe: Syntax Error (Missing Operation) in query expression Pin
RedPandinus12-Mar-19 9:04
RedPandinus12-Mar-19 9:04 
QuestionType conversion in VB.NET Pin
Revolution Radio9-Mar-19 3:03
Revolution Radio9-Mar-19 3:03 
QuestionRe: Type conversion in VB.NET Pin
Richard MacCutchan9-Mar-19 4:14
mveRichard MacCutchan9-Mar-19 4:14 
AnswerRe: Type conversion in VB.NET Pin
Revolution Radio9-Mar-19 5:22
Revolution Radio9-Mar-19 5:22 
GeneralRe: Type conversion in VB.NET Pin
Richard MacCutchan9-Mar-19 6:36
mveRichard MacCutchan9-Mar-19 6:36 
GeneralRe: Type conversion in VB.NET Pin
Revolution Radio11-Mar-19 0:43
Revolution Radio11-Mar-19 0:43 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.