I believe you are trying to set up Motor 4 as Gate3[1].Chan[0], even though the IDE expects it to be Gate3[0].Chan[3]. This was an issue in previous IDE versions, I am not sure exactly when it was corrected, but it seems to work fine in my IDE 4.6.0.14.
If you do not wish to update the IDE, you will have to set the following variables. These can be dragged into the terminal from the editor window.
Motor[4].pEncStatus=CK3WAX[3].Chan[0].Status.aMotor[4].pEncCtrl=CK3WAX[3].Chan[0].OutCtrl.aMotor[4].pCaptFlag=CK3WAX[3].Chan[0].Status.aMotor[4].pCaptPos=CK3WAX[3].Chan[0].HomeCapt.a
To sync these settings with the IDE project, right click on the motor folder and select "Sync All Motor Settings (PMAC to Project)".
If this is a sinusoidal encoder, you may also want to make sure the following settings are in affect:
Arctangent Enabled:
Gate3[1].Chan[0].AtanEna = 1
With Standard Sinusoidal:
Motor[4].EncType = 6
With ACI:
Motor[4].EncType = 7