0

i'm trying to load some data's to the listview from the offline database in my android application :) Here's the problem: in the database, i stored the link of the imageview. how can i use lazylist with it?! Here's my codeS:

list.setAdapter(null);
            Cursor cursor = dbHelpersamsung.listsamsung();
            String[] columns = new String[] { LebanonSamsung.KEY_URL, LebanonSamsung.KEY_PHONENAME,
                    LebanonSamsung.KEY_PRICE, LebanonSamsung.KEY_MODELNUMBER };

            int[] to = new int[] { R.id.thephoneimage, R.id.title2, R.id.details2,
                    R.id.modelnumber2 };
            SimpleCursorAdapter dataAdapter2 = new SimpleCursorAdapter(
                    this.getSherlockActivity(), R.layout.pricelistoffline,
                    cursor, columns, to, 0);
            list.setVisibility(View.VISIBLE);
            list.setAdapter(dataAdapter2);

How to use lazy list when loading images?? THANKS ALOT :D

1 Answers1

0

here is an interesting thread that can help you : Lazy load of images in ListView

Good luck

Community
  • 1
  • 1
  • Thanks for sharing! i know exactly how to load images from list adapter. but what about database? –  Aug 06 '13 at 00:32
  • Here is a step by step example http://wptrafficanalyzer.in/blog/asynchronously-populating-listview-from-sqlite-database-using-content-providers/ and an interesting feature http://greendao-orm.com/documentation/queries/ – mohamed khalloufi Aug 06 '13 at 06:33