I have a situation : 1. Create activity A with webview and from onCreate open another activity B. 2. On backpress/skip of B load a url in A.
@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState);
//this.getWindow().requestFeature(Window.FEATURE_PROGRESS);
setContentView(R.layout.activity_wap_launcher);
WebView webView = (WebView) findViewById(R.id.webView1);
final String url = "http://http:google.com";
webView.loadUrl(url);
Intent intent = new Intent(this, BManager.class);
this.startActivityForResult(intent,1);
}
Activity B opens on top of A but then suddenly it opens A with url.
Even i tried to use
@Override
protected void onNewIntent(Intent intent) {
final String url = "http://m.dittolite.com";
webView.loadUrl(url);
}
but it calls as soon as oncreate gets call.
Please suggest me a solution.