Ticker problem

Hello!
I've got a problem with the Ticker-function. I don't want my Ticker to reset (start over again) when i change between an application's Displayables. Does anybody know how to avoid this?
I supply an example where the Ticker will be reset if you select "Test-screen #1".
import javax.microedition.midlet.*;
import javax.microedition.lcdui.*;
public class TickerTest extends MIDlet implements CommandListener{
private Display myDisplay;
private Command backCommand;
private List myMenu;
private Ticker myTicker;
public void pauseApp(){}
public void destroyApp(boolean unconditional){}
public void startApp(){
if(myDisplay==null)myDisplay=Display.getDisplay(this);
initialize();
setDisplay(myMenu);
public void commandAction(Command c, Displayable d){
if(c == List.SELECT_COMMAND){
switch(((List)d).getSelectedIndex()){
case(0):
TextBox t=new TextBox("Foo", "Bar", 100, TextField.ANY);
t.addCommand(backCommand);
t.setCommandListener(this);
setDisplay(t);
break;
}else if(c==backCommand){
setDisplay(myMenu);
public void setDisplay(Displayable d){
d.setTicker(myTicker);
myDisplay.setCurrent(d);
private void initialize(){
myTicker=new Ticker("Tick Tack - this is a nice hack");
backCommand=new Command("Back", Command.BACK, 0);
String[] menuAlt={"Test-screen #1"};
myMenu=new List("Main menu", List.IMPLICIT, menuAlt, null);
myMenu.setCommandListener(this);
TY for any help!
-J�rgen-

Hi!
Here is an improved version. The first time you switch Display it still reset the ticker, but after that you go back and forth it works as it should be. I am not sure why it is not working the first time another display is switched, may be a bug or may be there is some work around which I am not getting.
import javax.microedition.midlet.*;
import javax.microedition.lcdui.*;
public class TickerTest extends MIDlet implements CommandListener{
     private Display myDisplay;
     private Command backCommand;
     private List myMenu;
     private Ticker myTicker;
     private TextBox t;
     private Form mainForm;
     private String[] menuAlt;
     public void pauseApp(){}
     public void destroyApp(boolean unconditional){}
     public void startApp(){
          if(myDisplay==null)
               myDisplay = Display.getDisplay(this);
          initialize();
          setDisplay(myMenu);
     public void commandAction(Command c, Displayable d){
          if(c == List.SELECT_COMMAND){
               switch(((List)d).getSelectedIndex()){
                    case(0):
                         setDisplay(t);
                         break;
                    case(1):
                         setDisplay(mainForm);
                         break;
          }else if(c==backCommand){
               setDisplay(myMenu);
     public void setDisplay(Displayable d){
          d.setTicker(myTicker);
          myDisplay.setCurrent(d);
     private void initialize(){
          myTicker = new Ticker("Tick Tack - this is a nice hack!");
          backCommand = new Command("Back", Command.BACK, 0);
          menuAlt = new String[]{"Test-screen #item1", "Test-screen #item2"};
          myMenu = new List("Main menu", List.IMPLICIT, menuAlt, null);
          myMenu.setCommandListener(this);
          t = new TextBox("Foo", "Bar", 100, TextField.ANY);
          t.addCommand(backCommand);
          t.setCommandListener(this);
          mainForm = new Form("Ticker");
          mainForm.addCommand(backCommand);
          mainForm.setCommandListener(this);
}

Similar Messages

  • Facebook chat and ticker problem

    A few days ago in my macbook the facebook ticker at the right side and also the chat doesn't displaying right. In my imac i don't have this problem. I erased the website data for facebook, also the cache but the problem exists. Any help for that? Thanks

    Ok. I know you emptied the cache but try this way instead.
    Open a Finder window. From the Finder menu bar click Go > Go to Folder
    Type or copy paste the following
    ~/Library/Caches/com.apple.Safari/Cache.db
    Click Go then move the Cache.db file to the Trash.
    Quit and relaunch Safari then try Facebook.

  • Reg.Delivery complete ticked problem

    Dear All
    Please help in this matter.
    In our partially goods received  Pos we ticked 'delivery complete' to prevent the further GRN.Using this ticked option how to prevent the further GRN.Then how to create system error message in OMCQ don't let the further GRN.
    Option 1 : Using the Latest GRN date option we can prevent the further GRN.
    Is there any possibility using the delivery complete ticked option can prevent the further GRN
    Thanks
    S.K Rajakumar

    Hi,
    Using Delivery Complete tick, you can not prevent the further GRN. By doing this, you only mark that you do not expect any further GRN & the PO should therefore not be considered for MRP. To prevent further GRN, change the PO quantity to actual quantity received.
    Hope this helps.
    Regards,
    Prashant

  • Box shading and tickness problem in smartforms Mainwindow

    Hello all,
    Can anyone guide me how to reduce shading and thickness of table frame lines?
    Also in main window table is displayed with dark black shad and with much thickness.
    how can i reduce this shade and thickness.
    for LP01 Device it is working fine , for LP02 Device It is not working.
    Please guide.
    Thanks & Regard,
        Sandeep.

    Hi Sandip,
    Window > output options > Box and shading > shading > saturation 5  to 10 %.
    Window > output options > Box and shading >frames  > width 15.00 TW
    Hope this helps.
    BR
    Dep
    Edited by: DeepakNandikanti on Aug 18, 2011 1:38 PM

  • I have a 2005 Jaguar xj8.  When I tried to upgrade my 3gs to a 4g I got a ticking noise in the speaker and no one on the other end could hear me.  I had to go back to a 3gs.  My phone is shot and I need to upgrade.  Has there been a fix to the problem?

    I have a 2005 Jaguar xj8.  When I tried to upgrade my 3gs to a 4g  two years ago, I got a ticking noise in the speaker and no one on the other end could hear me.  I had to go back to a 3gs.  My phone is shot and I need to upgrade.  Has there been a fix to the problem?  Apple told me there was some sort of interference with the airbag system.  Jaguar was totally unhelpful.

    Hi Labjock,
    Welcome to the Support Communities!
    The article below may be able to help you with this. 
    iPhone: Microphone issues
    http://support.apple.com/kb/ts5183
    Cheers,
    - Judy

  • Problem Gr/ir a/c where open line item is not ticked

    In gl master in gr/ir a/c open line item is not ticked and for that when we see the report from fbl1n it's showing in red and the problem is continuing from the implementation year 2009. what will be the simple solution.
    Regards
    abhisekh mandal

    Hi
    Check the link
    Change GL to open item managed
    Regards
    Sanil

  • Problems with the Widget "Text Ticker"

    Hello, I have a problem with the widget "Text ticker". I tried to put more then one text ticker on my site, but it doesn't work, when I look in Muse it looks like this:
    and when I look in the preview only the first text ticker works...maybe it is not possible to have more then one text ticker on one site?
    Thank you.

    It seems you are using the same name for all the ticker instances on page.
    You need to have unique names for each of the ticker you want on a single page. Tickers with duplicate names will not work.
    Cheers,
    Vikas

  • Recently, after cancelling the tick of a song, which is the next song after the one I am listening, in the song list, the canceled song will still run for the next song. I remember that it used not to happen like this. How can I solve this problem?

    Recently, after cancelling the tick of a song, which is the next song after the one I am listening, in the song list, the canceled song will still run for the next song. I remember that it used not to happen like this. How can I solve this problem?

    This looks like a change of behaviour in iTunes 12. Once songs are queued up to the Up Next list then they play whether ticked or not. If you want to skip certain songs already queued click the Up Next tool, then click the small X to the left of the song that appears when you hover over it.
    tt2

  • The safety site never tick auto fix ID andPasswords, why my security trading ac. still can auto fix my user ID.how to clear it, please teaching me to fix this problem.THANK YOU.

    M y firefox 10.0.2The safety site never tick auto fix ID andPasswords, why my security trading ac. still can auto fix my user ID.how to clear it, please teaching me to fix this problem.THANK YOU.

    http://www.omahapokernews.org
    http://www.holdempokernews.org
    http://www.7cardstudplay.net
    http://www.5cardstudplay.net
    http://www.holdemspot.org
    http://www.texasholdemstate.net
    http://www.texasholdemstate.com
    http://www.pokerbonuslist.net
    http://www.pokerdownloadz.org
    http://www.signuppoker.net
    http://www.tournamentpokerz.com
    http://www.pokercalculatorz.com
    http://www.omahaodds.org
    http://www.omahaouts.org
    http://www.texasholdemrulesonline.net
    http://www.onlineholdemtips.com
    http://www.pokerhilo.net
    http://www.poker-hilo.com
    http://www.hilopokers.com
    http://www.nolimit-holdempoker.net
    http://www.texasholdemlimits.org
    http://www.texasholdemlimits.net
    http://www.onlinepokerlimits.org
    http://www.onlinepokerlimits.net
    http://www.onlinepokerlimits.com
    http://www.texasholdemlimits.com
    http://www.7cardplayer.net
    http://www.5cardplayer.net
    http://www.omahaacademy.org
    http://www.omahapokerrooms.net
    http://www.onlinepokerroomstop.net
    http://www.playpoker-toppokerrooms.com
    http://www.texasholdemz.com
    http://www.playpokeronline-casinos.com
    http://www.texasholdem-vip.com
    http://www.gamble-poker-holdem.com
    http://www.playpoker-holdem.com
    http://www.onlinetexasholdem-poker.com
    http://www.texasholdempokeracademy.com
    http://www.vip-texasholdem.com
    http://www.playfree-poker-online.com
    http://www.texasholdem-pokerrooms.org
    http://www.toppokerrooms.ws
    http://www.toppokercasino.ws
    http://www.onlinepokercasino.ws
    http://www.playpoker-online.ws
    http://www.online-texasholdem.ws
    http://www.play-texas-holdem.ws
    http://www.internet-texas-holdem-poker.ws
    http://www.poker-player.ws
    http://www.luckyschool.com

  • Have Adobe Captivate 6 (not interested in upgrading)- Struggling to publish a simulation in a format that QMP can pickup - QMP needs a qml file. previous versions had no problem all had tick boxes for QMP in the Quiz - Reporting Settings but this version

    Have Adobe Captivate 6 (not interested in upgrading)- Struggling to publish a simulation in a format that QMP can pickup - QMP needs a qml file. previous versions had no problem all had tick boxes for QMP in the Quiz - Reporting Settings but this version does not have. If i publish to Flash QMP does not see the file.

    Re:
    The quiz review button is inconsistent - sometimes it shows the ticks and crosses other times it doesn't - did you find a solution? I'd dearly like to be able to tidy up the ticks!
    Thanks
    Sharon

  • Fs00 bdc problem in ticking checkbox fields

    Hello All,
    I have written bdc for tcode FS00 for gl master record upload but im getting error while uploading.
    In flat file i have putted value 'x' for posting without tax allowed, manage in local currency,open item and line item but when im running a bdc the checkboxes are getting checked but im getting the error "enter a valid value"
    If i create every account manually and tick the checkbox thn its not giving error but in bdc program if i m putting tick in checkbox im getting error
    Pls let me knw is there any other value of checkbox other thn 'x'?
    Thnks
    Sunny

    hi Sunny,
    just rin the BDS in mode A (show all screens) or E (stop at error), so that you'll see what is exactly the problem. I assume the problem is somewhere else (not by the checkboxes), for another field you enter a wrong value, which is not accepted by the system. Just check, where the cursor is placed, right after the error message!
    hope this helps
    ec

  • Despite ticking the box "remove all website data", when I reset Safari not  all stored cookies are eliminated. How can I overcome the problem? Or is it a bug?

    Despite ticking the box "remove all website data", when I reset Safari not  all stored cookies are eliminated. How can I overcome the problem? Or is it a bug?

    I have done a little experimenting: 1-close all open windows (I found that I had to do this step in order to keep Safari from hanging-will be explained later). 2: Remove all data in Prefs. 3: Immediately close the prefs window (no window should be open at this point) and quit Safari. Try to complete step 3 fast as possible; I have it down to a few seconds. The reason I urge you to close all windows is that Safari hangs until forced to quit upon immediately quitting after removing cookies. I think the auto page reload in Lion is the cause of these hiccups but I can't be sure about that. The hasty quit I found is crucial to success. Don't know why that is but it could prevent the data from re-populating. A quick flush, if you will.  Hit me back if you need any of my suggestions clarified; a bit wordy, I know

  • When I press slightly on either side of my macbook pro august 2011 trackpad or if I click the tracpad, I hear a light tick noise, sounds kinda like metal.  Anyone else have this problem? What is it?

    When I press slightly on either side of my macbook pro august 2011 trackpad or if I click the trackpad, I hear a light tick noise, sounds kinda like metal.  Anyone else have this problem? What is it?

    It's a spring-loaded grounding contact between the top case/chassis and the bottom pan of the machine. When you press, it scratches against the inside of the bottom pan and makes the sound. It's completely harmless and doesn't indicate that anything is wrong, but it can be slightly annoying. A visit to a Genius Bar may result in quieting it partially or completely.

  • HT4009 Ok so my problem is I put $100 on my account an it not letting me buy in app purchases an I'm ticked off to the max an idk how to fix this I bough in app the other day perfectly fine I need help bad HELP me

    Ok so my problem is I put $100 on my account an it not letting me buy in app purchases an I'm ticked off to the max an idk how to fix this I bough in app the other day perfectly fine I need help bad HELP me

    You need to Contact iTunes Customer Service and request assistance
    Use this Link  >  Apple  Support  iTunes Store  Contact

  • Slider with Synth - Problems setting tick and text color

    Hi,
    I'm currently using Synth and I'm having some problems with sliders. The sliders appear and work fine, although I can't seem to change the color of the ticks and text.
    I would like the ticks and text to be orange, but it seems to default to black. I tried changing this in the Slider section of my Synth file (see below) but with no luck.
    Would anyone have any suggestions?
    Thanks in advance for your help.
       <!-- ================================= -->
       <!-- SLIDER TRACK -->
       <!-- ================================= -->
       <style id="SliderTrackStyle">
          <imagePainter method="sliderTrackBackground" path="images/Slider/slider_track.png"
                        sourceInsets="7 7 7 7" destinationInsets="7 7 7 7" paintCenter="true"
                        stretch="true" center="false" />
          <state value="DISABLED">
             <imagePainter method="sliderTrackBackground" path="images/Slider/slider_track_disabled.png"
                           sourceInsets="7 7 7 7" destinationInsets="7 7 7 7" paintCenter="true"
                           stretch="true" center="false" />
          </state>
       </style>
       <bind style="SliderTrackStyle" type="region" key="SliderTrack" />
       <!-- ================================= -->
       <!-- SLIDER THUMB -->
       <!-- ================================= -->
       <style id="SliderThumbStyle">
          <font name="Arial" size="1" style="BOLD"/>
          <state>
             <!-- How do we set the slider text and tick colour -->
             <color type="TEXT_FOREGROUND" value="#8f5f00"/>
             <imagePainter method="sliderThumbBackground" direction="horizontal"
                           path="images/Slider/slider_thumb.png" center="true" />
             <imagePainter method="sliderThumbBackground" direction="vertical"
                           path="images/Slider/slider_thumb.png" center="true" />
          </state>
          <state value="PRESSED">
             <!-- How do we set the slider text and tick colour -->
             <color type="TEXT_FOREGROUND" value="#8f5f00"/>
             <imagePainter method="sliderThumbBackground" direction="horizontal"
                           path="images/Slider/slider_thumb_pressed.png" center="true" />
             <imagePainter method="sliderThumbBackground" direction="vertical"
                           path="images/Slider/slider_thumb_pressed.png" center="true" />
          </state>
          <state value="DISABLED">
             <imagePainter method="sliderThumbBackground" direction="horizontal"
                           path="images/Slider/slider_thumb_disabled.png" center="true" />
             <imagePainter method="sliderThumbBackground" direction="vertical"
                           path="images/slider_thumb_disabled.png" center="true" />
          </state>
       </style>
       <bind style="SliderThumbStyle" type="region" key="SliderThumb" />
       <!-- ================================= -->
       <!-- SLIDER -->
       <!-- ================================= -->
       <style id="SliderStyle">
          <property key="Slider.paintValue" type="boolean" value="false" />
          <property key="Slider.thumbWidth" type="integer" value="14" />
          <property key="Slider.thumbHeight" type="integer" value="14" />
          <!-- Cant seem to set the tick or text color -->
          <!-- <property key="Slider.tickColor" type="color" value="#8a8a00" /> -->
       </style>
       <bind style="SliderStyle" type="region" key="Slider" />Edited by: robben07 on May 18, 2010 7:36 AM

    I put the following code in the Title and it worked...
    <B><font face="Arial" size="+3" color="#244764">Text.....</FONT>
    the only problem is to know how to center it (I've tried putting <CENTRE> html tag but it's not working)... can you please advice...
    Thanks again for your assistance

Maybe you are looking for