There are 2 things.
If you have not yet posted the free text invoice, then on the action pane of the Free text invoice there is Invoice tab, there you will need to click on the Settle Open transactions in the Related information group. You will find the payments/advances that you want to knock off against the FTI. Please note that you will see only those advances against which Cash/Payment has been received in bank. As such, outstanding advance payments will not reflect.
Secondly, if the Free text invoice has been posted without adjustment of advance, you can go to Vendor master and then go to Settle tab in the action pane. Click on Settle open transactions in the Settle group.