Still waiting for a workable response for having a document open to last edit position

Version still doesn’t work consistently to open a document to the prior edit position. Doesn’t matter if the user name is entered in options, doesn’t matter if Apply User Data is reset in properties, doesn’t matter if Shift F5 is used, it just doesn’t work consistently. Maybe one day this bug will be worked out, but after ten plus years of using libreoffice I’m not hopeful.

Personal Data in LibreOffice

If you’ve already done all that in the link above, try:

First steps to take before submitting a bug

Good success!

Bug tdf#141586 . This is mainly a user forum so asking here doesn’t really help, maybe you could add yourself to the CC list for the bug.

1 Like

I was hoping someone might know of a solution that’s been suggested that doesn’t show up in a search. If not, then yes, I’ll submit as a bug. This is very annoying when you have documents that are 600 plus pages long

1 Like

Are your documents structurend with Heading n paragraphs? If so, double-clicking in the Navigator will scroll you to the heading. Not exactly the last edited position but this can narrow the search.

Developers do look at the CC list in a bug report, if there are a lot of people on it, it gets more attention. Maybe better to add to CC list of existing bug than to create a new one which will just get marked as a duplicate.

As a benefit of being in the CC list, any workarounds can that might appear in the bug report will be emailed to you directly.

1 Like

As alteady mentioned there is bug tdf#141586. What would you expect of a new report? If you found something specific in addition to what was already commented on that bug, you should also contribute there.

BTW1: The concept of restoring the position for a specific “author” is doubtable anyway. The software actually only can know the ID properties stored to the user profile. If such a profile only is used by one person we don’t know. In a well administered multi-user environment this should be organised, but…

BTW2: If you can accept the need of a few lines of custom code, there is a workaround.
Move the following code to a module of your local LibO and set onGoingToBeClosed as the handler for the respective document event. The attached example also contains this code, but keeping it in the document isn’t actually a good way to use it.

Function onGoingToBeClosed(Optional pEvent) As Boolean
onGoingToBeClosed = False
End Function

Sub createAutoBookmarkPositionWhenLastClosed(Optional pEventInfo)
REM Currently pEventInfo isn't evaluated.
cDoc       = ThisComponent
If NOT cDoc.supportsService("") Then Exit Sub
Const myPrefix = "auto_"
Const shortDTformat = "YYYYMMDDHHMMSS" REM preferred by my current camera, e.g. 
cCtrl      = cDoc.CurrentController
cSel       = cCtrl.Selection
REM If cSel.Count>1 only the position of the hair cursor is bookmarked.
insPos     = cSel(0)
newBm      = ThisComponent.createInstance("")
newBmN     = myPrefix & Format(Now(), longDTformat)
newBm.Name = newBmN 
cText      = insPos.Text
insCur     = cText.createTextCursorByRange(insPos)
cText.insertTextContent(insCur, newBm, True)
End Sub

autoBookmarkSimplified.odt (60.5 KB)

Of course, your consent to storing is indispenable. Unstored bookmarks won’t exist the next time the file is opened.

Can you tell a 101 step by step guide on how to do that? Or at least how to I set a handle for a Module? I’m totally lost. Thank you so much! <3

1 Like

Really annoying this is still not working -

Tools > Macros > Organize > Basic > MY Macros > Standard > Module1
[paste the code in there]

Tools > Customize > Events > Assign > Macro

1 Like

Ok thanks for the suggestion which I tried but it does not work. Yes it calls the macro as it should and it returns to a position, but by far the correct location - I would say off by about 70 pages!
I assume the macro was the one posted by Lupp nov 22

Would I have to add this to all my documents or is it tool based macro?

actually debugging it a bit, since e.g. shortDTformat is not used, and longDTformat not defined :wink:

that might be another bug.
indeed trying on War and peace 2000+ pages, also have it struggling with random page position before stabilizing … (?)
but, you can definitely go back to last bookmarked position through F5> Bookmarks, or Insert>Bookmark or the toolbar as in Lupp odt example.

up to you, in the Customize dialog you can use “Save in” to the current document or choose global “LibreOffice

This comment will surely be helpful.

Thank you so much!

this will never be solved. Libreoffice doesn’t care enough about to actually sit down and do a bit of programming. Users matter only for how many they can boast, not how many are satisfied even with something so simple.

Works for me with

Version: (X86_64) / LibreOffice Community
Build ID: d56cc158d8a96260b836f100ef4b4ef25d6f1a01
CPU threads: 16; OS: Windows 10.0 Build 22631; UI render: default; VCL: win
Locale: es-ES (es_ES); UI: en-US
Calc: CL threaded