I need a page which show web contents in a fixed width and height.
I put a webview inside a xml file with a height of 200px,but while loading that page,it directly redirect to default browser view.
While press the back button in the phone,it redirect to the original page,then the webview shows nothing.
in my xml file
<WebView android:layout_width="fill_parent" android:layout_height="200px" android:id="@+id/wvbrowser" />
in code
WebView wvbrowser;
wvbrowser=(WebView)findViewById(R.id.wvbrowser);
wvbrowser.loadUrl("http://www.orkut.com");
So tell me where I am Wrong? and how to show WebView in FIXED size?
Try this…
create a separate class.
Then in your activity use this.