Now it is giving me system error 85 has occured.

The local drive name is already in use.

any idea why is it happening
You are too funny...

if you used drive p to connect, then it is still connected until you use

net use p: /delete

you can't assign 2 shares to the same drive letter.

to find out what ones you are currently useing...

net use