Closed daredmayo closed 5 years ago
Hi @daredmayo,
I will need more than just “it doesn't work”. What commit are you using? Did you change something to the code? What error are you getting?
I know that the code for APA is still buggy and sometimes fails with merged citations. Can you provide a document which generates the error? I may be able to better track the problem.
Regards Luis
Hello Luis (@mabentwickeltsich),
I spend a good afternoon today trying to install your macros. They seem perfect! However, just as @daredmayo I seem to run into some troubles with the standard APA 6th edition style when trying to create some cross references.
I have gotten the IEEE style macro to work perfectly after some tries and the APA style macro will also run without any error. However when the APA style is applied using Mendeley the APA macro completes a run without adding hyperlinks to citations in the text that refer to the bibliography. In both cases the macro is still able to convert links within the bibliography itself.
This issue arises even when the document exists of nothing else but a citation and one corresponding reference in the bibliography. I did not modify the code in any way.
I am curious if you could help me resolve this issue.
Kind regards, Rinse
Hi @rsdonker,
Could you provide the document that produces the error? It would be much easier to test the macros with that document in order to track the bug.
Regards Luis
Hello @mabentwickeltsich,
Of course. I just made a small example file. Somehow I am not able to upload it with this comment but I did see you provided an email-address to another user on an already closed issue. Could I send the file to you there?
Kind regards,
Rinse
Yes, use that email please.
I just send you the document. I hope it arrived at the right address.
Hi @rsdonker,
I think i found the problem but it will take me longer to fully test and perhaps come with a better way to permanently solve the problem.
The way the data is stored within the citation field in Microsoft Word has changed; some blank spaces were removed. The regular expression, used to get information from those fields, expects the blank spaces and fails when they are not present.
Please, try a simple patch in line 340 where variable objRegExpCitationData.Pattern
is set:
\s
by \s*
(makes optional the blank space)'
in the beginningRegards Luis
Hello Luis,
Thank you for looking into this for me. Making the whitespace characters optional did indeed fix my main problem. The script runs again and creates hyperlinks as expected. If nothing else that makes me a happy man.
Kind regards,
Rinse
Edit: Removed the postscriptum as it did not belong to this thread
I assume @daredmayo was having the same problem.
Code already patched. Closing issue.
I have try your code and it works perfectly on IEEE style, but i can't use it on APA style. is that any update on APA style or something