×

Discussion Board

Results 1 to 7 of 7
  1. #1
    Registered User
    Join Date
    Feb 2008
    Posts
    14

    Images in J2ME Midlets

    hi,
    i developed a midlet that uses images to make buttons to control the application. everything works fine in the emulator (sun wireless toolkit 2.5), but when i load the midlet in the nokia 5610 xpressmusic i use for testing purpose, i cannot see the images (i checked in the jar file to see if all the pictures are present). is there a link between this situation and the fact that the midlet is not signed ? thank you in advance for your help.

    jonathan

  2. #2
    Nokia Developer Champion
    Join Date
    Sep 2007
    Posts
    915

    Re: Images in J2ME Midlets

    Did you put your images at res folder or somewhere else ? If you have put your images at classed folder first move it.


    -Kartik Trivedi

  3. #3
    Registered User
    Join Date
    Feb 2008
    Posts
    14

    Re: Images in J2ME Midlets

    hi kartik,
    thanks for your answer.
    i put the images in a "pics" folder which is in the "res" folder. i don't know what you mean by classed folder, and where do i need to moves the images ?

    jonathan

  4. #4
    Registered User
    Join Date
    Feb 2008
    Posts
    14

    Re: Images in J2ME Midlets

    hi,
    i still have have problems with the use of images in my midlet. from what i understood i don't need to put the images in the res folder (i am using the sun wireless toolkit 2.5), but where these images should be ? everything works fine with the emulator, but when i test my midlet on real phone (5610 xpressmusic), no image is displayed. thank you again for your help.

    jonathan

  5. #5
    Nokia Developer Champion
    Join Date
    Sep 2007
    Posts
    915

    Re: Images in J2ME Midlets

    I told you to move images from "classes" folder not from "res" folder. You do one thing first check if you are using canvas then check weather you are using following method or not to get height and width?



    int height=this.getHeight();
    int width=this.getWidth();

    Because some time this can happens because of it.

  6. #6
    Registered User
    Join Date
    Feb 2008
    Posts
    14

    Re: Images in J2ME Midlets

    thank you kartik, i solved the problem.

    jonathan

  7. #7
    Nokia Developer Champion
    Join Date
    Sep 2007
    Posts
    915

    Re: Images in J2ME Midlets

    You are welcome. Now always use getHeight() and getWidth() method whenever you use canvas.

    Happy Coding

    -Kartik Trivedi

Similar Threads

  1. Beginners Tutorial for J2ME
    By j2meed in forum Mobile Java General
    Replies: 3
    Last Post: 2013-11-07, 23:47
  2. How far can J2ME really go in doing some voice call stuff?
    By jin.z in forum Mobile Java Networking & Messaging & Security
    Replies: 4
    Last Post: 2008-01-29, 16:32
  3. Future of J2ME / MIDP
    By JWtheCoolOne in forum Mobile Java General
    Replies: 2
    Last Post: 2007-01-12, 14:09
  4. Symbian and non Symbian J2ME
    By thongtom in forum Mobile Java General
    Replies: 2
    Last Post: 2005-06-28, 10:52

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×