mabentwickeltsich / MendeleyMacros

New functionalities for Mendeley's plugin: hyperlinks for citations pointing to bibliography, hyperlinks for URLs in bibliography, and fix to maintain Microsoft Word style of bibliography.
41 stars 25 forks source link

Installation problem #4

Closed louislouiss closed 7 years ago

louislouiss commented 7 years ago

Hi,

I tried to install the macro but I don't understand what are the three lines I have to copy with the comment 'MabEntwickeltSich

Can you help me ?

Thank Louis

mabentwickeltsich commented 7 years ago

Hi @louislouiss,

Macros with name GAUG* are used to generate the hyperlinks, these are the important ones. You just need to copy the source code to Microsoft Word and do not forget to activate regular expressions (see Installation). Also remember the Microsoft Word style "Titre de dernière section” that you need to add to Microsoft Word or delete from the macros (see Extending/modifying the code)

When you insert the bibliography to your document and apply a Microsoft Word style to it (not a manual modification of style directly to the biblio), later when you refresh the bibliography, Mendeley will set back the Microsoft Word style of the bibliography to a predefined style reverting the changes you made. The macro refreshDocument is a modified version of the one installed by Mendeley. The three extra lines (identified by the text 'MabEntwickeltSich at the end of each one) are added to keep the Microsoft Word style when the bibliography is refreshed. If you do not want this “feature” then you do not need this. However, if you do want this “feature”, then to install it (or more accurately, to insert the three lines) you need to open the file Mendeley-1.16.1.dotm (on Microsoft Windows, but name depends on your version of Mendeley), find the macro refreshDocument in module MendeleyLib. Insert the three lines in their corresponding location and save the file. Open Mendeley Desktop, uninstall the Microsoft Word plugin and reinstall it again (see Installation).

I hope this clarify a bit more the installation of the macros. If still doubts, give me more details on what precise step is giving you trouble and the previous steps you did.

Cheers Luis

louislouiss commented 7 years ago

Ok so installation step is only required to add "refresh" macro.

So i think I have another issue, after adding the macro to word, when i tried to create links, i have "Compile Error: User-defined type not defined" (see picture)

How to solve this ?

Thx for your time Louis

macro_error

samuelduchesne commented 7 years ago

activate regular expressions : https://stackoverflow.com/questions/25102372/how-to-use-enable-regexp-object-regular-expression-using-vba-macro-in-word

SLD

On Sep 8, 2017, at 11:12 AM, louislouiss notifications@github.com wrote:

Ok so installation step is only required to add "refresh" macro.

So i think I have another issue, after adding the macro to word, when i tried to create links, i have "Compile Error: User-defined type not defined" (see picture)

How to solve this ?

Thx for your time Louis

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or mute the thread.

mabentwickeltsich commented 7 years ago

Thanks for the info @samuelduchesne, I apreciate it.

@louislouiss,

It seems that you have not follow the steps of the Installation process. As @samuelduchesne pointed it out, the error is due to the missing Microsoft VBScript Regular Expressions 5.5. I think I used these steps (step 1 only) when I was coding the macros, but the one posted by @samuelduchesne is also very good (steps 1 and 2 only).

I also assume that you have not added the Microsoft Windows style “Titre de dernière section” to your document; you will get another error. Either remove it from the macros or add it to Microsoft Word. And as last step, you also have to change If blnFound Then to If blnFound Or True Then otherwise the macros will not find the bibliography in your document.

Again, read the Installation and Extending/modifying the code as they contain important information.

A final word about refreshDocument. This macro is independent of all GAUG* macros and it is not required to be installed (more correctly, it is not necessary to add the three extra lines to the original macro). You install it only if you want the “feature” to keep the style of the bibliography (font, size, color, etc.) when you refresh the bibliography.

Cheers Luis

louislouiss commented 7 years ago

I activated regular expression and now it's all good.

Apparently it was the only problem because now I can create hyperlinks.

Thx both of you for helping me and you Luis for creating this awesome macro :)

Cheers Louis

mabentwickeltsich commented 7 years ago

Glad that you could fix the problem.

Closing issue