Hi Oz

May be you can find the Pk2cmd.exe file in the ... " C:\Program Files\Microchip\MPLAB IDE\ Pickit2 " folder ...

AND may be you could use those parameters ...

Code:
-P$target-device$ -F$hex-filename$ -E -M -B -L
But just up to you ...

Alain