aspose file tools
The moose likes Other JSE/JEE APIs and the fly likes Help in reading mobile number Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » Other JSE/JEE APIs
Reply Bookmark "Help in reading mobile number" Watch "Help in reading mobile number" New topic
Author

Help in reading mobile number

pooja prabhu
Ranch Hand

Joined: Sep 23, 2012
Posts: 33
hi

Can Anyone please tell me how to read mobile number example:9823145678 in java from excel

Thank you
James Peterson
Whizlabs Java Support
Ranch Hand

Joined: Feb 26, 2013
Posts: 105
Hi Pooja,

if you know how to read a excel file then you can do it by giving a condition to read only mobile number column from excel file.

Regards,
James


Whizlabs-Software, OCAJP 7 , SCJA 6 , SCJP 6 , OCPJP 7 , OCPJP 7- Upgrade ,SCWCD 5 ,OCEJWCD 6 ,SCBCD 5 ,SCEA 5 , PMP , PMI-ACP
Unconditional 100% Test PASS Guarantee!
pooja prabhu
Ranch Hand

Joined: Sep 23, 2012
Posts: 33
Thanks James
Actually i am new to java so can you elaborate?
Can You Tel Me how to do it..
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 35232
    
    7
What do you have so far, and where are you stuck making progress? If you haven't started, then you should get familiar with the Apache POI library for reading Excel files.


Android appsImageJ pluginsJava web charts
pooja prabhu
Ranch Hand

Joined: Sep 23, 2012
Posts: 33
yes i have already started
I take file name from text box
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 35232
    
    7
So what's still missing?
pooja prabhu
Ranch Hand

Joined: Sep 23, 2012
Posts: 33
i cant read correct mobile number. it saves 2147483647 instead of mobile number
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 35232
    
    7
You're treating the phone number as an integer, whereas you should be treating it as a string.
pooja prabhu
Ranch Hand

Joined: Sep 23, 2012
Posts: 33
i had tried it it gives me exception

java.lang.IllegalStateException: Cannot get a text value from a numeric cell
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 35232
    
    7
Then you need to change the spreadsheet so it doesn't format that field as a number. Phone numbers are strings, not numbers.
pooja prabhu
Ranch Hand

Joined: Sep 23, 2012
Posts: 33
what will be the format?
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 35232
    
    7
Which options do you see? Which one do you think makes sense?
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: Help in reading mobile number
 
Similar Threads
Trigger action on combo change
SCJP voucher available for 4500
Experienced Swing Programmers for Banglore
how to fetch mobile number
need to send the message by SMS and has to be received by web .