i am using d211 nokia pcmcia adapter on com4, there is no error with the code but there no respon either from the modem, and the sms still cant be received
Thanks
Main Topics
Browse All TopicsHi,
I can use Hyper Terminal to send sms using Infrared. The problem is that when I send, I need to type 2 times. Here is the example:
1- AT+CMGS="+91232538538"
2- > Hello GSM
3- Press Ctrl + Z and Enter
Now I want to use this command in VB. So I want to send only one command the sms will send. I tried this command but it's not work:
AT+CMGS="+91232538538",145
The problem is that how to send Ctrl-Z in VB?
Please help!
Thank you,
BM.
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
Business Accounts
Answer for Membership
by: imarshadPosted on 2006-02-16 at 23:11:08ID: 15978387
To my knowledge you cant send SMS in one line....
,1" 'Change this with the Baud rate of your modem (The one you use with Hyper Terminal)
Ctrl-Z is Character 26 in ASCII chart.... So you will be sending chr(26) for Ctrl-Z......
Here is a sample VB implementation...
Private Declare Sub Sleep Lib "kernel32" (ByVal dwMilliseconds As Long)
Private Sub Form_Load()
MSComm1.Settings="9600,n,8
MSComm1.CommPort=1 ' Change this with the port your Modem is attached
MSComm1.PortOpen=TRUE
End Sub
Private Sub Command1_Click()
MSComm1.Output = "AT+CMGF=1" & vbCrLf 'This line can be removed if your modem will always be in Text Mode...
Sleep 500
MSComm1.Output = "AT+CMGS=+91232538538" & vbCrLf 'Replace this with your mobile Phone's No.
Sleep 1000
MSComm1.Output = "Hello This is my test message"
Sleep 2000
If InStr(MSComm1.Input, "OK") Then
MsgBox "Message Send"
Else
MsgBox "Message Not Send"
End If
End Sub