&&(and) operator in IFF condition
Posted: Wed Aug 11, 2010 3:37 am
Hi
I am using the below code
{
IIF((Math.Round((Sum(DownloadTourMaster.CalculateAssigned)/Totals.Count(DataBand1)))>0) &&(Math.Round((Sum(DownloadTourMaster.CalculateTourHit)/Totals.Count(DataBand1)))>0),
(Math.Round((Sum(DownloadTourMaster.CalculateAssigned)/Totals.Count(DataBand1)) / (Math.Round((Sum(DownloadTourMaster.CalculateTourHit)/Totals.Count(DataBand1))
,
"N/A ( > 1.0 is tours too slow; <1.0 is tours too fast )"
)
}
but && operaotr is not working. Its checking the first condition. and showing error as Attempt to zero divide exception.
My first two condition is true.
1. How we use the && operator in two condition?
2. How we divide one value to another?
Thanks
Vikas
I am using the below code
{
IIF((Math.Round((Sum(DownloadTourMaster.CalculateAssigned)/Totals.Count(DataBand1)))>0) &&(Math.Round((Sum(DownloadTourMaster.CalculateTourHit)/Totals.Count(DataBand1)))>0),
(Math.Round((Sum(DownloadTourMaster.CalculateAssigned)/Totals.Count(DataBand1)) / (Math.Round((Sum(DownloadTourMaster.CalculateTourHit)/Totals.Count(DataBand1))
,
"N/A ( > 1.0 is tours too slow; <1.0 is tours too fast )"
)
}
but && operaotr is not working. Its checking the first condition. and showing error as Attempt to zero divide exception.
My first two condition is true.
1. How we use the && operator in two condition?
2. How we divide one value to another?
Thanks
Vikas