Push new screen when documentLoaded from the BrowserField in Blackberry?
===

Hi friends in my application i have a log in screen when the user enter the correct user name and password i have to collect the information from the website and navigate to main screen in my application ..

 i tried this way...

    public final class MyScreen extends MainScreen {
    public MyScreen() {

		BrowserFieldConfig myBrowserFieldConfig = new BrowserFieldConfig();
		myBrowserFieldConfig.setProperty(BrowserFieldConfig.NAVIGATION_MODE,
				BrowserFieldConfig.NAVIGATION_MODE_POINTER);
		BrowserField browserField = new BrowserField(myBrowserFieldConfig);

		BrowserFieldListener list = new BrowserFieldListener() {
			public void documentLoaded(BrowserField browserField,
					Document document) throws Exception {

				String url = document.getBaseURI();
				String val = "http://demo.....";
    //i am checking the correct url and i will navigate to main screen
				if (url.equals(new String(val))) {
					UiApplication.getUiApplication().pushScreen(new Main());

				}

				System.out.println(" Login  URL " + url);
				//super.documentLoaded(browserField, document);
			}

		};
		browserField.addListener(list);
		add(browserField);
		String URL = "http://demo.....";
		if (DeviceInfo.isSimulator()) {
			URL = URL + ";deviceSide=true";
		}
		browserField.requestContent(URL);

	}
    }


this is not working..
How can i achieve it? 