cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
mj7
Helper I
Helper I

info gallery

hello i have a register that when i upload, it goes to another screen wich is the info that i already register so my question is how i can make that the information i registered goes to the info screen but on top of the gallery i alredy put a sort icon but i rather have the info un top so the user dont have to click the sort icon everytime. Hope you can help 🙂 

11 REPLIES 11

@RandyHayes i think my formula is not okay 😞 it marks error

If(!IsBlank(vardatesort),SortByColumns(DOORTRIM,"FECHAYHORA",If(vardatesort=true, Ascending,Descending)),DOORTRIM);

DropColumns(
SortByColumns(
AddColumns(DOORTRIM,
"FECHAYHORA",FECHAYHORA=Formdoort.LastSubmit.CÓDIGO
),
"FECHAYHORA",
Descending
),
"FECHAYHORA"

})

@mj7 

Yes, that definitely is not going to work.

Use this formula instead:

DropColumns(
    SortByColumns(
       AddColumns(DOORTRIM,
           "FECHAYHORA",FECHAYHORA=Formdoort.LastSubmit.CÓDIGO,
           "NoOrdenar", true
       ),
       If(IsBlank(vardatesort), 
          "NoOrdenar",
          "FECHAYHORA"
       ),
      Descending
    ),
    "FECHAYHORA",
    "NoOrdenar"
)

 

Since you don't want any sorting if the vardatesort is empty, this formula sets a "dummy" column with true in it and then sort on that if it is blank.  Otherwise it sorts on the date and time added column.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
NOTE: My normal response times will be Mon to Fri from 1 PM to 10 PM UTC (and lots of other times too!)
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!

Helpful resources

Announcements
Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (4,440)