Yes sure you can get the code which is actually being set right now, without loosing / damaging any data/contacts.. anything.
All you need is the USB Data Cable, which comes with the new phone.
IF you have one, no need to worry, just follow the steps described by one of out experts,
here.This is a standard procedure and works 100%, I've tested it a number of times with full success.
Read it carefully, if you have any confusion, ask me before doing anything.
I hope this will help you out.
If you think I was of help, your token of appreciation in the form of rating will be esteemed.Concerned, DNR.