Many routers have the password / code printed on the base. If all else fails and you don't have the admin password or network password you may have to reset the router.
Find the manual online and download before starting. You may find your answers in the manual!! If that doesn't work, follow the instructions to reset back to factory settings. You will then have to reconfigure the network, including setting new passwords.
Also before doing it, check with your service providers support page and make a note of all the settings you need for logging on. Most routers require initial setup using a cable, so make sure one is to hand before resetting anything!
Good luck. If it's any consolation, I've just spent the best part of the day sorting out networking problems on my parents machines. Boxing Day fun. Not.