https://bugs.documentfoundation.org/show_bug.cgi?id=173730

--- Comment #2 from Floris <[email protected]> ---
>In your case you need fixed date/time fields, not variable ones.

My use-case is converting EXISTING documents written by others to .pdf

Unfortunately, I cannot control which type of fields were originally put in
there.
Even if it are not fixed fields but dynamic ones, I would like an option to
have the original date displayed there.


The original date certainly does is stored in Word .docx documents, even if it
concerns dynamic fields.
If you extract such .docx documents with unzip, and view the document.xml
inside the dynamic field shows as:

==
<w:r><w:fldChar w:fldCharType="begin"/></w:r><w:r><w:instrText
xml:space="preserve"> TIME \@ "dd-MM-yyyy" </w:instrText></w:r><w:r><w:fldChar
w:fldCharType="separate"/></w:r><w:r><w:rPr><w:noProof/></w:rPr><w:t>24-09-2026</w:t></w:r><w:r><w:fldChar
w:fldCharType="end"/></w:r>
==

As you can see, the file has a dynamic date, but it also has the original
24-09-2026 date hidden in it as well.

Microsoft Word does display such original date in certain cases. E.g. if it is
an Outlook e-mail attachment, and you open it in read-only mode. So other
products do can do it.


Unfortunately, Libreoffice always updates the date on import, and does not
currently have an option to let it display the 24-09-2026 date instead.


The closest I found is the hidden environment variable option called
STABLE_FIELDS_HACK:
https://github.com/LibreOffice/core/blob/3b602bc4fc8ef4119b82b28bcaff810628239509/sw/source/core/fields/flddat.cxx#L66

But then the all dates get set to 30/12/1899, which is not what I want
either...

-- 
You are receiving this mail because:
You are the assignee for the bug.

Reply via email to