简体   繁体   中英

Refresh specific line in a datasheet view in Access

I have a form in "Datasheet" mode in Access 2003 which can contains 25 000 lines.

When I want to edit a specific line, I open a specific form which contains all the editable field.

Once finished, I save and close the form but now I'd like to requery and refresh only the line I edited. (I want to keep the cursor at this line, and I'd like to avoid reloading every line so a requery on the form isn't the solution).

Is it possible ?

Regards

No, I don't think it is. You would have to requery your form, but you can put your cursor back where it was by saving the AbsolutePosition before you do so:

lngPos = Me.Recordset.AbsolutePosition
Me.Requery
Me.Recordset.AbsolutePosition = lngPos

By the way, I stole this idea from Albert D. Kallal on pcreview . I have used the Bookmark object in the past, but it always seemed buggy.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM