Rob,

Glad to see your working through the design and issues.
You are very close.

Here are a couple of things you need to correct.
1. VRCON: Look at the register description in "Register 8-3" on page 53 of the datasheet.
In your program you are setting VRCON like this: VRCON = %00001000 'voltage reference
There are more bits in the register that you need to take into account.
A. You have bit7=0 which does this "0 = CVREF circuit powered down, no IDD drain and CVREF = VSS". This turns OFF the internal reference voltage.
You need to change this to "1", 1 = CVREF circuit powered on, to turn on the internal reference voltage circuit.
B. You have bit5 = 0 which does this "VRR: CVREF Range Selection bit 0=High Range"
This changes your CVref equation and result to this: "VRR = 0, CVREF = (VDD/4) + (VR3:VR0 X VDD/32)", which when you plug in your values you get this
for your reference voltage. (3.3/4) + (8/32) = (0.825) + (0.25) = 1.075 Vdc. Now this may be what you were actually trying to do, if so then your are good.

2. In your main loop you are attempting to test the output of the Comparator like this: "IF CMCON0.1 = 1 THEN"...
Look at the CMCON0 register description in "Register 8-1" on page 47 of the datasheet and compare that with the "CMCON0.1 = 1" above.
You are testing bit1 of the CMCON0 register, that is what the ".1" does. xxxx.1 says I want to look at bit1 of xxxx.
Is this the bit you need to check for the Comparator Output? If you're not sure have a look at "FIGURE 8-3" on page 49 and look at the figure for the
CM Mode you are using "100". That diagram indicates what the Comparator Output is by name.

Check and correct this.

3. Lastly, and somewhat obscure in the DS, you need to determine how you want the Comparator to test and output.
As I understand you want to check the input pin voltage against your "1.075 Vdc" reference you are setting up internally and have the following outcomes:
If the input is "Lower than 1.075 Vdc" you want the LED to be OFF and you want the LED to be "ON when the input is Higher than 1.075 Vdc".

To get these results you need to take a look at a couple of items in the datasheet.
A. Look at CMCON0, "Register 8-1" on page 47, and review the information for bit6 and bit4.
Also look at "TABLE 8-1" on page 48.
Between these two, you should be able to piece together how you need to configure the operation to get your desired "Output" of the Comparator.

You are getting close, hopefully these additional points will get you further on your way.

Regards,