If the desktop application that you are using does not automatically refresh the links in a document when you open it, you can use this method to refresh them manually.
CALL METHOD document->update_document_links
EXPORTING no_flush = no_flush
IMPORTING error = error
retcode = retcode.