Results 1 to 15 of 15
Thread: PC and HandPhone...
- 03-31-2010, 04:28 PM #1
Member
- Join Date
- Mar 2010
- Posts
- 41
- Rep Power
- 0
PC and HandPhone...
Hi,
If I develop a software with java, can it run on mobile phones too?
Let's say, I coded a program using NetBeans -> Desktop Java Application with Database and I put it in website. Can I see this application if I connect to that website through my hand phone or PDA?
I made a simple Application with that way. I copied the .jar file to my PDA's memory, when I try to run, it says "Invalid Java application descriptor (jad)"
Do we have to code especially for mobile phones or it actually works but i am missing something?
Thank You.
- 03-31-2010, 05:34 PM #2
Moderator
- Join Date
- Apr 2009
- Posts
- 10,484
- Rep Power
- 16
JavaME.
That's the one for mobiles and small devices.
There'll be a version of it for the device you want to target.
As for the website thing, I don't quite understand...is this a webapp, or a desktop app for download through the site?
- 03-31-2010, 05:57 PM #3
Senior Member
- Join Date
- Mar 2010
- Posts
- 953
- Rep Power
- 4
- 03-31-2010, 05:59 PM #4
the api and patterns in j2me looks quite different then those in j2se. look at this simple piece of code and compare it to a HelloWorld code in j2se.
Java Code:import javax.microedition.lcdui.*; import javax.microedition.midlet.*; public class HelloWorld extends MIDlet{ private Form form; private Display display; public HelloWorld(){ super(); } public void startApp(){ form = new Form("Hello World"); String msg = "Hello World!!!!!!!"; form.append(msg); display = Display.getDisplay(this); display.setCurrent(form); } public void pauseApp(){} public void destroyApp(boolean unconditional){ notifyDestroyed(); } }
creating the jad-file is quick done compared to translate your j2se-code for j2me.
- 03-31-2010, 06:01 PM #5
Moderator
- Join Date
- Apr 2009
- Posts
- 10,484
- Rep Power
- 16
- 03-31-2010, 06:44 PM #6
Member
- Join Date
- Mar 2010
- Posts
- 41
- Rep Power
- 0
So it means that, if I want a software which runs both in pc and handphone, I can't do it by just coding it once and copy here and there..(of corz..! but I thought java could..)
Ok then, Let me ask this question with another way..
What would you do if someone asks you to develop a desktop java application which collaborates with online database and integrate it with mobile phones? :( (not iPhone. Java app for mobile.. or a way to run the java desktop app directly on hp like using an emulator... sounds like trying to run tetris on a 12 digit calculator. :D)
Maybe I should ask this too... : Is it possible?
Thanks..Last edited by OmerHalit; 03-31-2010 at 07:21 PM. Reason: to make it clearer... :)
- 03-31-2010, 07:10 PM #7
If you want to create iPhone apps, you need to learn Objective-C.
- 03-31-2010, 08:14 PM #8
Member
- Join Date
- Mar 2010
- Posts
- 41
- Rep Power
- 0
What I had in my mind was to develop a java desktop application. pin it to a website.
then go to that website from my PDA which uses windows mobile 2003 and see the java application there..
is this possible?
- 03-31-2010, 08:42 PM #9
i would ask for which device and then look which sdk is available for this device. in the device specification you should also see which browser protocols are available and if these protocols are compatible with your online db. by the way, this forum has also a subforum for Java ME. You will find the specials there.
what mobile phones are you talking about?Last edited by j2me64; 03-31-2010 at 08:45 PM.
- 03-31-2010, 08:45 PM #10
Member
- Join Date
- Mar 2010
- Posts
- 41
- Rep Power
- 0
let's say nokia n90 or O2 PDA which supports java and uses windows mobile 6.0
Last edited by OmerHalit; 03-31-2010 at 08:52 PM.
- 03-31-2010, 09:06 PM #11
ok, this device supports CLDC 1.1 and MIDP 2.0. nokia recommend S60 Platform SDKs for Symbian OS, for Javaâ„¢ developers. good luck.
- 03-31-2010, 09:15 PM #12
Member
- Join Date
- Mar 2010
- Posts
- 41
- Rep Power
- 0
So I see that "coding once running twice" is not possible :D If I want my software run on pcs and hps, I have to code it twice..
Thank you for your helps.. especially j2me64.. :)
so how come this person could ask me that question?
Develop a java desktop application which collaborates with online database and integrate it with mobile phones?
Either he meant something else or he doesnt know what he is saying.. or do you understand something else?
- 03-31-2010, 09:18 PM #13
Senior Member
- Join Date
- Mar 2010
- Posts
- 953
- Rep Power
- 4
Realistically, the "Write Once, Run Anywhere" ideal just doesn't always work. Do you really want your desktop users confined to a tiny screen, for instance? Do you expect your mobile device users to have a full keyboard and mouse?
-Gary-
- 03-31-2010, 09:27 PM #14
Member
- Join Date
- Mar 2010
- Posts
- 41
- Rep Power
- 0
yeah, it's logical.. thank you for your helps.. I hope to see you in this forum again while healing my another wound.. :D starting a nice path finder java app.. cheers..
- 04-01-2010, 09:09 AM #15
Moderator
- Join Date
- Apr 2009
- Posts
- 10,484
- Rep Power
- 16


LinkBack URL
About LinkBacks
Reply With Quote

Bookmarks