Hello all,
I'm trying to a complicated sort. I feel like this post https://powerusers.microsoft.com/t5/Building-Power-Apps/Sorting-Gallery-by-selecting-column-from-ComboBox/td-p/801611 gets me close but I'm not sure I understand it completely. @jbrit2020 maybe you can help me understand the solution you provided?
Screen 1: User selects items > these items get put into a collection
Screen 2: ComboBox default selected items is the collection from screen 1.
On Screen 2 I have a gallery that filters based on several factors with one being the previously mentioned ComboBox.
I would like to sort my results in the Gallery based on columns that match the names in the ComboBox. The columns are Text Columns that have either "Protected", "Compatible", "Not Protected".
Right now I have a formula that will sort the results but by all columns and not only the ones listed in the ComboBox (cbmetals). This currently doesn't help sort the results in a useable way. I want to sort the results to have those with "Protected" in the columns listed first, followed by "Compatible".
Current Formula Part 1

Part 2

Do I have to do If statements for each column? So If Cast Iron in cbmetals then x, y, z? Then do that for every one?