alt-r/file/new add following lines...

on *:NOTICE:*This nickname is registered and protected*:?:{
if (($nick = Nickserv) && ($me == opnicknamehere) && ($network == opnetworknamehere)) { NS identify passwordhere }
if (($nick = Nickserv) && ($me == opnicknamehere) && ($network == opnetworknamehere)) { NS identify passwordhere }
if (($nick = Nickserv) && ($me == opnicknamehere) && ($network == opnetworknamehere)) { NS identify passwordhere }
if (($nick = Nickserv) && ($me == opnicknamehere) && ($network == opnetworknamehere)) { NS identify passwordhere }
if (($nick = Nickserv) && ($me == opnicknamehere) && ($network == opnetworknamehere)) { NS identify passwordhere }
}

Nick sending message must be NICKSERV
You set the "opnicknamehere" to your op nick
You set the "opnetworknamehere" to your network ( if u dont know it u should, if u dont know it, in mirc type in $network and press TAB key)
You set the "passwordhere" to ya password
I put five lines on so u can do it for 5 different ops u might have etc, but if u only got one just remove the other 4. If u got 7 add 2 more etc.

PS: I use the NS command to the server which everywhere I ever been is the same as /msg nickserv , this way in case some dodgy person has managed to pretend to be NickServ they wont get the message as its a ccommand direct to the server.

PSS: if the wording is different from nickserv "This nickname is registered and protected" then change it.