I got an exact opposite problem. I could work only in program mode. Facing problems with the debug mode.
44 pin - PIC 18F47J53
When i try to work in the debug mode, most of the times I get this error message.
PK3Err0040: The target device is not ready for debugging.
Please check your configuration bit settings and program
the device before proceeding.
Sometimes it works and sometimes it does not. I do not know what to do with the configuration bit settings for the debug mode. Is there any difference in setting those bits from the compiler or from the code?? I could not find anything (like the DEBUG bit referred by many controllers) regarding the debugging in the configuration bit registers. Please let me know how to work in the debug mode.
Coming to your problem, What happens when you select the pickit 3 programmer ?? Does it detect the target board ??