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



Comment Added by : pablo

Comment Added at : 2014-08-03 16:10:55

Comment on Tutorial : How to Send SMS using Java Program (full code sample included) By Emiley J.
I am receiving an error as
Error java.lang.NullPointerException
The code is

package p1;
import javax.comm.*;
import p1.SMSClient;
public class test{

private static int sendMessage;

/**
* @param args
*/
public static void main(String[] args) {
try{
SMSClient obj=new SMSClient();
int n=obj.sendMessage("9062322456", "test");
}
catch(Exception e){System.out.println("Error " +e);}

//Error java.lang.NullPointerException
}
}


I would also like to knwo where is the smsc number in these four files and where can i find it in ??
Is it the operators code??


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. Hi, thank you so much for this. I am going to give
View Tutorial          By: Eddie at 2011-02-21 14:10:04

2. Very nice article.. thanks
View Tutorial          By: Basu at 2010-05-29 05:52:00

3. what will be the answer of this?
int y=10;<

View Tutorial          By: divye at 2015-03-20 09:05:46

4. Thanks. Your post was clear and worked perfectly a
View Tutorial          By: Suma at 2009-03-05 09:40:08

5. thanks i understood
View Tutorial          By: raksha at 2012-11-04 16:44:19

6. I'm using BSNL broadband modem,,from that how can
View Tutorial          By: souvik at 2011-12-22 08:12:50

7. Abstract class example is good, What is the differ
View Tutorial          By: megakumar at 2011-04-10 04:15:10

8. Thank you. It is very good.
View Tutorial          By: tapes pra at 2011-12-08 09:23:31

9. How to execute above sqlstr file.
View Tutorial          By: shriyash at 2014-02-23 09:32:36

10. Very good description. I was quite confused before
View Tutorial          By: Donna at 2011-07-31 03:46:05