Looking for a strategy for taking notes in Writer

I do a lot of work with Writer documents, and I’m looking for a way to take notes that I can easily access later on.

What I have in mind is a macro to take selected text, highlight it and make an endnote out of it. I think that would work fairly well, but am I overlooking something already built in to LO (5.1.4.2), or does anyone have any other ideas?

Thanks.

Hi

I do not see exactly the purpose of what you want but these actions are recordable: cut (selected text), insert end note, paste. So, something like:

document   = ThisComponent.CurrentController.Frame
dispatcher = createUnoService("com.sun.star.frame.DispatchHelper")
dispatcher.executeDispatch(document, ".uno:Cut", "", 0, Array())
dispatcher.executeDispatch(document, ".uno:InsertEndnote", "", 0, Array())
dispatcher.executeDispatch(document, ".uno:Paste", "", 0, Array())

Regards

Thanks, Pierre. I would copy rather than cut, and optionally mark the text in place with something like underlining, but that’s the basic idea. I’m looking to gather the notes from various places in the text to one place, and I thought an endnote stream, aside from any footnotes the doc might have, would be a pretty good way to do it. But I’m opening this up to any other suggestions.