Hi everyone,
I'm looking today to have the TemplateFill in gallery depending of excel table value.
In my gallery I browse this table :
The column "Spectacle" is filled by value from this table :
And on the last table I made Column with the color designed (theses colors are coming from somes other files and are the same for all the company)
I want to have the templatefill in the Gallery as the colors wrote in this table.
I find how to change color with switch function but, I have some gallery, and I case of change colors or add colors, I need to change all of theses. That's what I want to do it automatically if it's possible.
Maybee someone as an idea of which formula use to do this.
Thank's for all, and have a good day.
Solved! Go to Solution.
Hi Everyone,
I found the exact formula to do this :
RGBA(LookUp(liste_spectacle;Spectacles=ThisItem.Spectacle).spectacle_couleur_rouge;LookUp(liste_spectacle;Spectacles=ThisItem.Spectacle).spectacle_couleur_vert;LookUp(liste_spectacle;Spectacles=ThisItem.Spectacle).spectacle_couleur_bleu;LookUp(liste_spectacle;Spectacles=ThisItem.Spectacle).spectacle_couleur_opacite)
Many thank's to show me the way.
Have good day 🙂
Hi, assuming PowerApps recognises it as a colour (when you over over the RGB vale a colour appears) then you just need the change the fill in the gallery to ThisItem.[ColumnName]. I have not done this with Excel but have with SharePoint and it works as expected. You need the make sure the RGBA value is written exactly the same as when a colour is manually selected in PowerApps. It might be that when the data is collected it store it as text, in this case just add the number part of the colour to the excel and for the fill property add RGBA(ThisItem.[ColumnName])
@C-Papa ,
This is not working for me, and also I could be work if the colors and all values are in the same table, but I'm not in this case.
Thank's anyway for your answer
In that case you will need to create a connection to the table with the colours in and do a lookup within PowerApps to match the correct colour to the correct item. For this to work you need something in both tables that indexes the colour to the item.
@C-Papa ,
I thinking to this way, but I don't know how to make this connection. I have the same Index as nommed Spectacle.
With the Lookup fonction I can find a table type, but I need to extract only a value in the Color columns.
Also in Fill formula, I can't have access to external value.
Thnak's for reply 🙂
Hi Everyone,
I found the exact formula to do this :
RGBA(LookUp(liste_spectacle;Spectacles=ThisItem.Spectacle).spectacle_couleur_rouge;LookUp(liste_spectacle;Spectacles=ThisItem.Spectacle).spectacle_couleur_vert;LookUp(liste_spectacle;Spectacles=ThisItem.Spectacle).spectacle_couleur_bleu;LookUp(liste_spectacle;Spectacles=ThisItem.Spectacle).spectacle_couleur_opacite)
Many thank's to show me the way.
Have good day 🙂
User | Count |
---|---|
251 | |
106 | |
96 | |
50 | |
39 |