Comment on Tutorial - How to Send SMS using Java Program (full code sample included) By Emiley J.



Comment Added by : Asela

Comment Added at : 2012-01-26 18:53:51

Comment on Tutorial : How to Send SMS using Java Program (full code sample included) By Emiley J.
Hi
I have done all the steps mentioned above but I still get this exception
javax.comm.NoSuchPortException
at javax.comm.CommPortIdentifier.getPortIdentifier(CommPortIdentifier.java:105)
at SerialConnection.openConnection(SerialConnection.java:70)
at Sender.send(Sender.java:44)
at SMSClient.run(SMSClient.java:39)
at java.lang.Thread.run(Thread.java:662)
java.lang.NullPointerException
at SerialConnection.openConnection(SerialConnection.java:87)
at Sender.send(Sender.java:44)
at SMSClient.run(SMSClient.java:39)
at java.lang.Thread.run(Thread.java:662)
BUILD SUCCESSFUL (total time: 0 seconds)


I'm trying to use this on a Windows 7 OS
and my
javax.comm.properties file looks like this

#
# Drivers loaded by the Java Communications API standard extension
# at initialization time
#
# Format:
# Each line must contain ONE driver definition only
# Each line must be of the form:
# driver=<ClassName>
# No spaces or tabs in the line.
# ClassName must implement the interface javax.comm.CommDriver
# example: driver=Win32Serial
#
#
# The hash(#) character indicates comment till end of line.
#
# Windows Serial Driver
Driver=com.sun.comm.Win32Driver
Im not sure whether I have to add any addition to this
plz help to over come this :)


View Tutorial



Subscribe to Tutorials

Related Tutorials

Program using concept of byte long short and int in java

Update contents of a file within a jar file

Tomcat and httpd configured in port 8080 and 80

Java File

Java String

Count number of vowels, consonants and digits in a String in Java

Reverse a number in Java

Student marks calculation program in Java

Handling Fractions in Java

Calculate gross salary in Java

Calculate average sale of the week in Java

Vector in Java - Sample Program

MultiLevel Inheritance sample in Java

Multiple Inheritance sample in Java

Java program using Method Overriding

Archived Comments

1. nice code. code is running perfectly. but my probl
View Tutorial          By: Avinash at 2013-01-28 07:30:19

2. thanks, i will try. but can u tell me how to send
View Tutorial          By: ketut joko wibawa at 2011-01-02 05:18:01

3. does this code work with netbeans. if not can anyo
View Tutorial          By: Alton at 2010-04-02 22:36:57

4. "For example, float can be useful when repres
View Tutorial          By: David at 2009-10-08 13:47:08

5. how to use tokenizer "No.1 hello,No.2 world,N
View Tutorial          By: saanu at 2011-03-04 00:41:21

6. How do you remove an element from the map?
View Tutorial          By: Shreejit at 2012-01-29 16:53:27

7. Hi,
I'm studying core java.java is new for

View Tutorial          By: shantkumar at 2011-12-01 17:02:26

8. Very cool one, thanks, got the concept clear
View Tutorial          By: black boot at 2010-04-18 08:20:20

9. Thank you!!!!!
View Tutorial          By: wsjonly at 2013-09-19 18:41:50

10. FYI, if you're using NetBeans, the input file shou
View Tutorial          By: pberg at 2013-03-28 17:00:16