Background switch detected for MyApp (24) who doesn't have the tunnels open - defocus is NOT called

I get the error "background switch detected for MyApp (24) who doesn't have the tunnels open - defocus is NOT called. Then the Simulator freezes and I can't do anything. Tried to debug but no luck!

My application has two other entry points implemented from article http://www.blackberry.com/knowledgecenterpublic/livelink.exe/fetch/2000/348583/800738/800901/How_To _...

Please see code below

public class UserInterface extends UiApplication{

    public static void main(String[] args){

        if ((args != null) && (args.length > 0) && (0==StringUtilities.compareToIgnoreCase(args[0].toString(), "GUI"))){

            UserInterface theApp = new UserInterface();
            theApp.enterEventDispatcher();
        }
        else {
            try
            {
                Wait();
                            SetTimer();
                ManageResources mg = new ManageResources();
                System.exit(0);

            }
            catch (Exception ex)
            {
                if (RuntimeConfig.DEBUG)
                {
                    System.out.println("UserInterface, main:  " + ex);
                }
            }
        }
    }
    public UserInterface() {
        //  DialogDisplay dd = new DialogDisplay();
        pushScreen(new UserInterfaceScreen(this));
    }

I also had this problem, the cause is that my computer is behind a proxy firewall so that MDS services Simulator cannot connect to internet, I added the following lines in the file rimpublic.property in the directory "Eclipse\plugins\net.rim.eide.componentpack4.7.0_4.7.0.46\components\MDS\config".

application.handler.http.proxyEnabled = true
application.handler.http.proxyHost = proxyserver
application.handler.http.proxyPort = 8080

These lines must be placed in the [MANAGER HTTP] section.

It will be useful.

Tags: BlackBerry Developers

Similar Questions

Maybe you are looking for