how to show scroll bar in listview
I am new to Phonegap. I am displaying a list of data in a list view. There
are 1000+ rows data, so the scroll bar is shown, but it is shown inside
the whole page, I want to show it in listview. Any one can help me. Thanks
in advance.
First I add a page with a listview
<div data-role="page" id="listview" data-add-back-btn="true">
<div data-role="header">
<h1>Listview</h1>
</div>
<div data-role="content">
<div data-role="listview" data-inset="true" id="listview1"></div>
</div>
</div>
and then I add 100 items to listview
for (var i = 0; i < 100; i++)
{
$("#listview1").append("<li><a href='#'>Item" + i + "</a></li>");
}
result is scroll bar is shown in page, I want to show scroll bar in
listview and make listview height fill parent
No comments:
Post a Comment