Rather than adding a new macro project, open the Macros Explorer (View/Other Windows/Macro Explorer), and right-click on MyMacros and select New Module.
In the New Module dialog, enter the name "DuplicateLastLineModule". The module DuplicateLastLineModule then appears in the Macro Explorer. Double click it to open the macro editor. Replace the contents with the macro text from the blog you linked to. The key here is that the name of the module file should match that in the declaration "Public Module DuplicateLastLineModule"
Save the module.
From Visual Studio, open Tools/Options/Keyboard.
In the field "Show commands containing", type "Duplicate". You should see an entry in the list beneath reading "Macros.MyMacros.DuplicateLastLineModule.DuplicateLine". Select it. Click on the "Press shortcut keys" field and press the key sequence that you want to use to invoke the macro. Click OK.
From an editor window, type a line of text, and press your key sequence. The macro should then launch and duplicate the line.
Good luck!