Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

downloading

 
Shierley Kencana
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How to download file from a server to mobile phone using http connection?
 
Lasse Koskela
author
Sheriff
Posts: 11962
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Shierley Kencana:
How to download file from a server to mobile phone using http connection?

 
Shierley Kencana
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for the answer. But I'm still confused. With that code is the file automatically saved to the phone?
 
Lasse Koskela
author
Sheriff
Posts: 11962
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Shierley Kencana:
With that code is the file automatically saved to the phone?

No, you only get an InputStream to read bytes from (into memory). You have to deal with writing the byte[] into RMS (persistent storage) yourself.
I'd suggest investing into a J2ME book, but if you're not excited about spending $, you should browse the Web for specific articles. Good places to start would be at least:
  • http://www.microjava.com/articles (especially this for using RMS)
  • http://www.enterprisej2me.com/articles.php
  •  
    Lasse Koskela
    author
    Sheriff
    Posts: 11962
    5
    • Mark post as helpful
    • send pies
    • Quote
    • Report post to moderator
    Oh, forgot to add this article about J2ME networking from my bookmarks...
     
    • Post Reply
    • Bookmark Topic Watch Topic
    • New Topic