visual studio 2010 - Error on RDLC Expression -


i using exp calculate total fees paid on rdlc report:

=sum(iif(fields!responsedescription.value ="approved successful",int(fields!amount.value), 0)) 

and #error in resulting column , can issue ? .

and similar exp above work fine :

=sum(iif(fields!responsedescription.value <> "",int(fields!amount.value), 0)) 

few notes:

1- amount integer , present.

2- responsedescription string , present.

thank you

you can use expression:

=sum(cint(iif(fields!responsedescription.value ="approved successful", fields!amount.value, 0))) 

you have convert every possible values same type before aggregation.

i think second expression works fine because in true case (fields!responsedescription.value <> "") used expression converted integer.


Comments

Popular posts from this blog

php - Zend Framework / Skeleton-Application / Composer install issue -

c# - Better 64-bit byte array hash -

python - PyCharm Type error Message -