TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
sathish v
NA
323
2k
List sqlite database Table in xamarin.android
Jul 27 2018 7:41 AM
I Want To List All Tables in sqlite database table,
When i tries to List the table contents It Only Shows the First columns of table.
AXML Page:;
<LinearLayout xmlns:android=
"http://schemas.android.com/apk/res/android"
android:orientation=
"vertical"
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
>
<ListView
android:layout_width=
"fill_parent"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"0dp"
android:clickable=
"true"
android:divider=
"#b5b5b5"
android:dividerHeight=
"1dp"
android:id=
"@+id/listView1"
/>
ANd CS Page
string dpPath = Path.Combine(System.Environment.GetFolderPath(System.Environment.SpecialFolder.Personal),
"BookmarkSqlite.db3"
);
var db =
new
SQLiteConnection(dpPath);
var data = db.Table<BookmarkSqliteTable>();
foreach (var listing in data)
{ var from =
new
string[]{ listing.SiteName +
"----"
+ listing.SiteUrl };
//var from = fromm.ToList();
ListView listtable = (ListView)FindViewById(Resource.Id.listView1);
listtable.Adapter =
new
ArrayAdapter(
this
, Android.Resource.Layout.SimpleListItem1, from);
}
}
i tried ToList on from,but it also not works
listtable.Adapter =
new
ArrayAdapter(
this
, Android.Resource.Layout.SimpleListItem1, from.ToList());
Reply
Answers (
1
)
how access hidden filed value in web method method in c#
xamarin.forms(cross-platform)