Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6589261
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T17:09:03+00:00 2026-05-25T17:09:03+00:00

I coded a j2me application using LWUIT. It works fine on emulator as well

  • 0

I coded a j2me application using LWUIT. It works fine on emulator as well as a symbian device. But when i tried to run it on a nokia s40 device,it showed up a “nothing to display” message. I tried displaying a splash screen, as prescribed in some forums. Still,the app never gets past the splash screen.

EDIT 1

        Display.init(this);
        Resources r = Resources.open("/theme.res");
        UIManager.getInstance().setThemeProps(r.getTheme(r.getThemeResourceNames()[0]));

        Dialog splash = new Dialog("Splash Screen");
        splash.setAutoDispose(true);
        splash.setTimeout(5000);
        splash.show();

        RecordStore rs = null;
        byte[] buffer = null;
        rs = RecordStore.openRecordStore("xxxxxx", true);
        if (rs.getNumRecords() > 0) {
            buffer = rs.getRecord(rs.getNumRecords());
            num = new String(buffer, 0, buffer.length);
            rs.closeRecordStore();
    offer(num);   // a method which displays main form
        } else {
            rs.closeRecordStore();
            registration("xxxxx"); //another method which displays the secondary form
        }

In this snippet,a blank screen is displayed on the device after the dialog/splash screen.
The form gets displayed when i remove the codes managing the RecordStore.
How do i fix this mess ?

EDIT 2
Code for registration()

        Form f = new Form();
        f.setLayout(new BoxLayout(BoxLayout.Y_AXIS));
        Image img = Image.createImage("logo.png");
        f.addComponent(new Label(img));
        Label lbl = new Label(msg);
        f.addComponent(lbl);
        f.addComponent(new Label("xxxxx"));
        final TextArea number = new TextArea(1, 10, TextArea.NUMERIC);
        f.addComponent(number);
        Button btn = new Button("Register");
        btn.addActionListener(new ActionListener() {

            public void actionPerformed(ActionEvent evt) {
                //perform rms related activities and move onto offer()
            }
        });
        f.addComponent(btn);
        Button help = new Button("Help?");
        help.addActionListener(new ActionListener() {

            public void actionPerformed(ActionEvent evt) {
                //display a help dialog
            }
        });
        f.addComponent(help);
        f.addCommandListener(this);
        f.show();
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T17:09:04+00:00Added an answer on May 25, 2026 at 5:09 pm

    Change the splash.show() to splash.showModeless()

    Regardless your code is incorrect since it assumes show() will display the dialog immediately which is not how most GUI frameworks work. Your method needs to complete and return control to LWUIT in order for the dialog to show. However, you read the RMS and then the code to show your form is unclear, when do you expect it to actually occur.

    You need to show the dialog without a timeout (I would use a form for the splash screen there is no reason to use a dialog), then open a thread (new Thread(…)) to do whatever you want and then when the thread completes show your form.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm working on a J2ME application using LWUIT. I need to show 10 values
I am using LWUIT package for my j2me application.In my application, i have extends
Im developing a mobile application in j2me.Im using Nokia c2-01 mobile for testing.In my
I am using Sun java wireless toolkit 2.5.2 and LWUIT for my j2me application.I
I have a j2me midlet running on a cell phone. The code works fine,
I coded something using Date statement in Access VBA. It was working fine until
I want to make am HTTP GET request from my J2ME application using HttpConnection
I have application building using third party apis, j2me apis,application code distributed in various
is there any limit to send data from j2me device to server. I coded
I am working with nokia N97.And my application is in j2me.Problem i am facing

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.