×

Discussion Board

Results 1 to 4 of 4
  1. #1
    Regular Contributor
    Join Date
    Sep 2005
    Posts
    138

    Default Command in Alerts

    Hello

    I have created an Alert to which I added a Gauge object. The problem is that when it appears on screen, I get a command "Accept" that I do not want. ("Aceptar" in the image, I'm spanish)

    Code:
    Gauge gauge = new Gauge( null, false, Gauge.INDEFINITE, Gauge.CONTINUOUS_RUNNING);
    
    alertaIdioma = new Alert(text1, text2, null, AlertType.INFO);
    
    alertaIdioma.addCommand(new Command(" ", Command.OK, 0));
    
    alertaIdioma.setIndicator( gauge );
    
    alertaIdioma.setTimeout(Alert.FOREVER);
    
    miDisplay.setCurrent(alertaIdioma, miDisplay.getCurrent());

    I have read that this command appears when there is no other, by default to dissmiss the alert, so I tried to add a command "Empty" but keeps coming.

    Code:
    alertaIdioma.addCommand(new Command(" ", Command.OK, 0));
    If I try to add a Command to the Gauge, the Alarm doesn't appears!!!

  2. #2
    Registered User
    Join Date
    Oct 2009
    Location
    Noida
    Posts
    941

    Re: Default Command in Alerts

    If I try to add a Command to the Gauge, the Alarm doesn't appears!!!
    Not clear, do you mean Alert doesn't come ?
    Try alertaIdioma.addCommand(new Command("a ", Command.OK, 0)); and see if Aceptar is gone.
    Thanks,
    Ekta

  3. #3
    Super Contributor
    Join Date
    Nov 2003
    Location
    Bangalore , India
    Posts
    4,429

    Re: Default Command in Alerts

    May be you should give a try by changing Command.OK to Command.SCREEN.

    Regards
    Gopal

  4. #4
    Regular Contributor
    Join Date
    Sep 2005
    Posts
    138

    Re: Default Command in Alerts

    Hi!

    Finally I recompile and...it works O_o. Maybe I was installing an old MIDlet?

    Thank you!!!

Similar Threads

  1. How can we use default command ........
    By jainendra.pathak in forum General Development Questions
    Replies: 7
    Last Post: 2007-09-16, 12:30
  2. How can we use default command ........
    By jainendra.pathak in forum News and Announcements
    Replies: 1
    Last Post: 2007-09-13, 09:05
  3. how to programme on the default command??
    By qubeleymkii in forum Mobile Java General
    Replies: 0
    Last Post: 2006-06-12, 12:38
  4. 9500 default alerts/notifications
    By goldmanbunce in forum Audio
    Replies: 0
    Last Post: 2005-07-15, 08:46
  5. Removing Default Exit Command
    By fazalkhan in forum Mobile Java General
    Replies: 2
    Last Post: 2005-01-19, 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
  •  
×