Instructions
Connect your Action Replay device to your computer via the USB cable that came with the device.
Start the "Action Replay Code Manager Software" that came with your Action Replay peripheral. The program will automatically detect the connected Action Replay device.
Right-click the "My Codelists" panel at the bottom-right of the screen.
Click "Add new cheat" from the list of options. A small window will appear.
Type a name for the cheat and enter the code for Shadow Lugia. The code will vary for each game, but it can typically be found any site where Action Replay codes are found.
Click "OK" to save the code.
Perform the action associated with the code. Some codes will require you to enter the grass to fight Shadow Lugia, while some codes will place the Pokemon in your mailbox. A detailed description of how the code works should be shown with the Action Replay code.