I want to display the content of an html page and an image to the right of that in my view.
So i have defined my layout as
<ScrollView android:id="@+id/scrllvwNo1"
android:layout_width="fill_parent" android:layout_height="wrap_content">
<RelativeLayout android:layout_width="wrap_content"
android:layout_height="fill_parent" android:background="@drawable/home_bg">
<ImageView android:id="@+id/aboutcmkimage"
android:layout_width="wrap_content" android:layout_height="wrap_content"
android:layout_alignParentRight="true" android:src="@drawable/about"
android:padding="5dip" />
<WebView android:id="@+id/aboutcmk" android:layout_width="wrap_content"
android:layout_height="fill_parent" android:textColor="#000000"
android:layout_toLeftOf="@+id/aboutcmkimage"
android:layout_alignParentTop="true" android:layout_alignParentLeft="true" />
</RelativeLayout>
</ScrollView>
and
I try to load the html page as below
WebView web = (WebView)findViewById(R.id.aboutcmk);
web.loadData(getString(R.layout.about),"texl/html","utf-8");
in this case i am getting the error "this page contains error at line1 ... "
if I try
web.loadDataWithBaseURL(null,getString(R.layout.about),"texl/html","utf-8",null);
no html output and no error
In both case the image is coming
Can anyone help me in debugging
My html has bullets , so i cannot use textview instead of webview
here is the definition of my htmlstring in xml file
<string name="About"><html><body><b>What is CMK?</b> ......</body></html>
Thanks a lot for the help
<string name="About">in your HTML specification. Could you clarify what it is? As far as I know HTML doesn't have any such tag.