Forum Discussion

RyanStanford1's avatar
RyanStanford1
Qrew Captain
6 years ago

Sort by Color Coding

I have an embedded report which is set up where if key fields are empty, they will have a red background... I then have JS code which will pop up an alert if red background is present on the page... this works great...

What I'm being asked by users is if there's a way to have these red background rows automatically at the top of the report.

From what I can see, QB doesn't have a "Filter/Sort by color" function, like in MS Excel... 

Any help would be greatly appreciated, and thanks in advance.

4 Replies

  • Is there anything special about the embedded report beyond your JS code to alert them? Assuming you're just using a standard report link / embedded report - you should be able to sort the report by your key field in order such that those missing will appear on top. 

    Chayce Duncan | Technical Lead
    (720) 739-1406 | chayceduncan@quandarycg.com
    Quandary Knowledge Base
    • RyanStanford1's avatar
      RyanStanford1
      Qrew Captain
      That would work, except that the color coding searches for more than one column... So I can't just set the default sort to that column.
    • ChayceDuncan2's avatar
      ChayceDuncan2
      Qrew Cadet
      My recommendation would be to make a new formula that mimics the logic in your color coding - and then use that as the sort for your report. So if your report has 3 colors lets say - make this formula field calculate 1, 2, 3 etc, and sort by that.

      Chayce Duncan | Technical Lead
      (720) 739-1406 | chayceduncan@quandarycg.com
      Quandary Knowledge Base
    • RyanStanford1's avatar
      RyanStanford1
      Qrew Captain
      I'll give that a shot... sort of a round about way of doing it... but if it works... then it works.