program a PIC with PICKIT 3

Microchip do provide a tool called 'MPLAB  X IPE' which can program the PICs together with their 'MPLAB  IDE'. You can download the tool here

During the installation process you can decide if you want to install both IDE & IPE or IPE only.

The tool can work with the original Microchip Pickit3 but do work also with the clones offered at Aliexpress.

connect the pickit 3 to your USB port and place the PIC and jumpers as shown in the picture
start the IPE
your pickit3 should be shown up in the 'tool' section together with the serial number.
select advanced mode
goto power and select "Power target circuit from pickit 3". Choose a voltage level of 4.75V as especially the clone devices have problems to provide 5Volt
Choose 'PIC18F45K22' as device. Click 'apply' and then 'connect'. The tool will download necessary software to the pickit3 and show the type of the target device in the text field.
If this fails with the error message shown in the picture, check power settings again (they sometimes get lost) and repeat the step.
now select the hex file you want to use via 'browse' and push 'program'