I'm trying to make an automatic invoice but the final part gets me stuck. If a client is not from the same country as the supplier then he shouldn't pay VAT. To get this in my invoice I'm trying to insert an expression but it gives the following error:
'The Value expression for the textrun ‘Textbox16.Paragraphs[0].TextRuns[1]’ contains an error: [BC30455] Argument not specified for parameter 'FalsePart' of 'Public Function IIf(Expression As Boolean, TruePart As Object, FalsePart As Object) As Object'.'
This is the expresion I use:
=IIf(First(Fields!CustomerCountry.Value, "Invoice"))<>(First(Fields!SupplierCountry.Value, "Invoice")),0,((SUM(Fields!DurationHours.Value * Fields!HourlyRate.Value))*0.21)
Can anyone help please?
Thanks in advance
You have an extra parenthesis in your iif statement, at the first First function. Try this instead:
=IIf(First(Fields!CustomerCountry.Value, "Invoice")<>(First(Fields!SupplierCountry.Value, "Invoice")),0,((SUM(Fields!DurationHours.Value * Fields!HourlyRate.Value))*0.21))
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With