Hi Nick,
I suspect it might be the "-" (a Special Character) that is confusing the formula parser, and suggest you try this, to give it a hint:
valueexpression=SUB({DE:INV - Total Invoice Amount},{DE:Tekside Cost})
Regards,
Doug
P.S. DE stands for "data extensions", for those who've wondered, and means "custom data"