Complex Conditional Formatting And Dates

3 replies. Last post: September 1, 2009 12:27 AM by Glenn Layaar
Tags :
  • (None)
  • New Discussion
  • New Question
  • New Product Feedback
A YousifMember

I'm using the following custom condition to highlight a row based on the status of failed (1) and where something was submitted two weeks ago.  However, it doesn't do anything.  Can you help me identify what's wrong please?  I would also appreciate some complex examples of how to use the Between and NotBetween for boty Row and Cell types.  Thank you.

   fmt = new ISNet.WebUI.WebGrid.WebGridFormatCondition();
   fmt.Name = "condition4";
   fmt.CustomConditionText = "[reportRunStatusID] = 1 and [dateSubmitted] > '" +
      DateTime.Now.AddDays(-14).ToString(PRISM.Xtensions.Date.CPRISMDate.CFmtDateTime.Std24) + "'";
   fmt.TargetObject = ISNet.WebUI.WebGrid.TargetObjectType.Row;
   fmt.FormatStyle.Font.Bold = true;
   fmt.FormatStyle.ForeColor = System.Drawing.Color.Green;
   fmt.Enabled = true;

The custom condition evaluates, as of this morning, to this for example:
"[reportRunStatusID] = 1 and [dateSubmitted] > '12 Aug 2009 10:14:52'"

 

All times are GMT -5. The time now is 3:37 AM.
Previous Next