From: Schollnick, B. <Ben...@xe...> - 2005-07-19 15:29:13
|
> Do you need to re-retrieve the whole table ? Technically at this time, no. But in theory, this database could be accessed by multiple systems at the same time... And thus it is safer to refresh the entire table then it is to reread just a single row. > I'm surprised that the time to load the whole table from the DB, then=20 > load that whole thing into the multicolumnlist is small=20 > enough for the=20 > extra 1-2 seconds to matter. Reading the table from the database is very fast... The majority of the time involved in the gather_data routine is the Dialog window redrawing the data.... > But .... it looks to me as though what you're doing in the loop > is getting the row number where the current_item was *before*=20 > any edit to the db. Quite possible. I just did a simple check to see how it woruld work. > I'd have thought that once you'd edited (or deleted or=20 > added), it could be in a different row number - no ? Yes... It could... But even if the data is indifferent position, I don't mind the cursor being where it was previously. =20 These are software titles, etc... (It's a auditing system...) So if your editting "Norton Utilities v2.0", probably you'll want to edit something nearby... > Can't you remove that loop entirely, and get the line number=20 > while loading the table from the DB : It is possible. For some reason (I forget), I did not want to do that...... I'll make a quick model... Possibly lost in the email was a small issue... 1) SetSelected does not reposition the list to be in the visible area. Is there some other way to force the selectedvalue to be in the visible area of the dialog? - Benjamin |