locked
conditional display of values based on date value RRS feed

  • Question

  • User-1474096950 posted

    =Fields!pname.Value+ "                           " +IIf(cdate(Fields!dtfrm.Value)="01-01-1900","",cdate(Fields!dtfrm.Value)+ " to "+cdate(Fields!dtto.Value) )

    i want tht if the date is 01-01-1900 then the value shld be blank else display value frm db

    Friday, September 28, 2012 9:51 AM

All replies

  • User276895905 posted

    your fields!dtfrm.Value is a date object? if it is , then you need to use value.toString("MM-dd-yyyy)

    Friday, September 28, 2012 1:08 PM
  • User-1474096950 posted

    using above i get wrong no of arguments

    Saturday, September 29, 2012 7:25 AM
  • User-1051986203 posted
    use below code :
    =Fields!pname.Value+ "" + Switch(cdate(Fields!dtfrm.Value) = "01-01-1900", "",cdate(Fields!dtfrm.Value) <> "01-01-1900",cdate(Fields!dtfrm.Value)+" to "+cdate(Fields!dtto.Value))

     

     

    Tuesday, October 16, 2012 12:55 AM