Click here to Skip to main content
15,883,905 members
Please Sign up or sign in to vote.
1.50/5 (2 votes)
See more:
Hi,
I am doing sms project in which sms coming from customer should read automatically and fetch the data from database as per sms received and send db info to same mobile no. throw sms.
If message has received into the serial port how can it will read automatically so please help me regarding this.
Posted
Comments
[no name] 10-Aug-12 9:25am    
Reading the documentation is usually a good place to start. http://msdn.microsoft.com/en-us/library/system.io.ports.serialport.datareceived.aspx
Sergey Alexandrovich Kryukov 10-Aug-12 13:05pm    
So, what's the problem? Working with a serial port? If it's something else, there is no enough information.
--SA
manjunathmk 20-Aug-12 8:20am    
when message came into sim then alert should be produce so we can read the message from sim and proceed the further operation.

1 solution

If your only problem is reading from a serial port (you did not explained what do you mean by "automatically"), you need to use the class System.IO.Ports.SerialPort:
http://msdn.microsoft.com/en-us/library/system.io.ports.serialport.aspx[^].

Better don't use asynchronous operations but do all the communication is a separate thread.

—SA
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900