I'm working on a dues process in version 15.2.0 for accrual dues, and I'm trying to access the invoice table using the CINVOICE invoice= new CINVOICE(user, reference number) constructor but I get an error stating:Specified cast is not valid.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Any recommendations would be greatly appreciated, Thanks!