Hi All,
I have this rdl formula that I made and tried to rebuilt again and again but I keep on getting an error saying there too many arguments in it for one iif statement. Does anybody over here notice what is wrong:
Interesting enough this one gives the error:
=IIF(Sum(Fields!totallineitemamountValue.Value, "DSMainHeader") <= 0
,""
,
iif(First(Fields!wvdb_directdebitValue.Value, "DSMainHeader") = false
,
iif(Sum(Fields!LE_a3dab734625bea315c9a57b87486dd44_wvdb_correspondencelanguageValue.Value, "DSMainHeader")) = "899250001"
,
iif(cdate(Parameters!HLBDate.Value)>Cdate(First(Fields!wvdb_printedonValue.Value, "DSMainHeader")) and CDATE(First(Fields!wvdb_printedonValue.Value, "DSMainHeader"))>cdate(Parameters!Date.Value)
,
First(Fields!LE_6025318c5699bdbae794ee0908a6cde6_wvdb_bankaccountinformationenglish.Value, "DSMainHeader") &" "& First(Fields!psa_bankaccountnumber.Value, "DSMainHeader") &" / "& First(Fields!psa_bankidentificationcode.Value, "DSMainHeader"),
First(Fields!LE_6025318c5699bdbae794ee0908a6cde6_wvdb_bankaccountinformationenglish.Value, "DSMainHeader") &" "& First(Fields!wvdb_hlb_bank.Value, "DSMainHeader") &" / "& First(Fields!wvdb_hlb_bic.Value, "DSMainHeader")),
iif(cdate(Parameters!HLBDate.Value)>Cdate(First(Fields!wvdb_printedonValue.Value, "DSMainHeader")) and CDATE(First(Fields!wvdb_printedonValue.Value, "DSMainHeader"))>cdate(Parameters!Date.Value)
,
First(Fields!LE_6025318c5699bdbae794ee0908a6cde6_wvdb_bankaccountinformationdutch.Value, "DSMainHeader") &" "& First(Fields!psa_bankaccountnumber.Value, "DSMainHeader") &" / "& First(Fields!psa_bankidentificationcode.Value, "DSMainHeader"),
First(Fields!LE_6025318c5699bdbae794ee0908a6cde6_wvdb_bankaccountinformationdutch.Value, "DSMainHeader") &" "& First(Fields!wvdb_hlb_bank.Value, "DSMainHeader") &" / "& First(Fields!wvdb_hlb_bic.Value, "DSMainHeader"))
,
iif(Sum(Fields!LE_a3dab734625bea315c9a57b87486dd44_wvdb_correspondencelanguageValue.Value, "DSMainHeader")) = "899250001",
"This invoice is collected by direct debit authorization.",
"Deze factuur wordt automatisch geïncasseerd."))
but this one is working, however it's not suitable for the ssrs header as it doesn't refer to a specific dataset:
=IIF(Fields!totallineitemamountValue.Value <= 0
,""
,
iif(Fields!wvdb_directdebitValue.Value = False
,
iif(Fields!LE_a3dab734625bea315c9a57b87486dd44_wvdb_correspondencelanguageValue.Value = "899250001"
,
iif(cdate(Parameters!HLBDate.Value)>Cdate(First(Fields!wvdb_printedonValue.Value, "DSMain")) and CDATE(First(Fields!wvdb_printedonValue.Value, "DSMain"))>cdate(Parameters!Date.Value)
,
Fields!LE_6025318c5699bdbae794ee0908a6cde6_wvdb_bankaccountinformationenglish.Value &" "& Fields!psa_bankaccountnumber.Value &" / "& Fields!psa_bankidentificationcode.Value,
Fields!LE_6025318c5699bdbae794ee0908a6cde6_wvdb_bankaccountinformationenglish.Value &" "& Fields!wvdb_hlb_bank.Value &" / "& Fields!wvdb_hlb_bic.Value),
iif(cdate(Parameters!HLBDate.Value)>Cdate(First(Fields!wvdb_printedonValue.Value, "DSMain")) and CDATE(First(Fields!wvdb_printedonValue.Value, "DSMain"))>cdate(Parameters!Date.Value)
,
Fields!LE_6025318c5699bdbae794ee0908a6cde6_wvdb_bankaccountinformationdutch.Value &" "& Fields!psa_bankaccountnumber.Value &" / "& Fields!psa_bankidentificationcode.Value,
Fields!LE_6025318c5699bdbae794ee0908a6cde6_wvdb_bankaccountinformationdutch.Value &" "& Fields!wvdb_hlb_bank.Value &" / "& Fields!wvdb_hlb_bic.Value))
,
iif(Fields!LE_a3dab734625bea315c9a57b87486dd44_wvdb_correspondencelanguageValue.Value = "899250001",
"This invoice is collected by direct debit authorization.",
"Deze factuur wordt automatisch geïncasseerd.")))
Do you see where I am going wrong? Thanks a lot for your help