|
-
Jun 5th, 2018, 07:55 PM
#1
Re: fast write of database recordset to listview
Well It looks like you are reading the data from the recordset into a variable then reading the data from that variable into another variable then reading from that variable into the list view so that is adding time to the process how much I can't say but there is no need for the 2 extra assignments. You can read directly from the recordset into the listview saving steps, lines of code and time. You also can make the listview not visible while adding item which will speed it up a bit, not sure if listview has an option to turn off auto redraw or not. If that option exists that also will speed it up, a lot if you are adding a lot of data as it does not have to keep redrawing itself.
I also notice that you are calling LTrim. You really should not have leading spaces in your data that need to be trimmed off but if you do then make sure to only use trim on the fields that may need it and use the proper string version LTrim$() rather than the slower variant version LTrim()
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|