web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Last record to display...
Power Apps
Answered

Last record to display in textinput

(0) ShareShare
ReportReport
Posted on by 27

Hello everyone,

I'm having an issue with PowerApps that would benefit from your help:)

The issue:

I have a sh list with columns: 

Model Make Version Equipment Reference Month Budget

test     test     test       test            test           test      test

 

I have in the list over 100 rows. At the beginning of every month, business has to create this items all over again, the only thing that is different is the Budget. I have created a gallery and used the patch defaults to create all items at once. 

THing is that for budget i created a TextInput for Budget that the business has to document. They would like to have each month, as hint text (or as default item but with the possibility to modify) in the TextInput, the value entered last month that corresponds to all other columns.  

 

I cannot manage to make it work, any ideas?

Thank you!

 

 

 

Categories:
  • RuneBH Profile Picture
    24 on at

    Hi Cosmin, 

     

    Lets say for Budget you want to default display last months value you could in the property "Default value" put formula like this:

     

    Text(First(Sort(MyList, ID, Descending)).Budget)

     

    Where "MyList" is the SharePoint list that you are using to hold the info and "Budget" is the field that holds the budget data. 

    If you use the same form for both creating and updating the items you can use this formula:

     

    If(IsBlank(Parent.Default), Text(First(Sort(MyList, ID, Descending)).Budget), Parent.Default)

     

    This will only take last months default in case the Budget is empty, else it will display the Parent.Default (what ever is already in the field on the SharePoint list for the current item). 

     

    Hope that it makes sense 🙂

  • Verified answer
    cosmin89 Profile Picture
    27 on at

    Hi @RuneBH ,

    Thanks for your support!

    I tried Text(First(Sort(MyList, ID, Descending)).Budget) and it works but with one issue:

    I use a gallery, and it brings the same value to all rows. This is not good for me, since the fields Model, Make, Version, Equipment and Reference have different values that are related. For each row in the gallery, i need to compare all columns values from the gallery with the ones from the list and bring the latest budget value for each.

    Not sure how to acomplish that, any suggestions will help:)

    Thank you!

  • Verified answer
    RuneBH Profile Picture
    24 on at

    Aha ok, makes sense. So if I understand you correct, you want to identify an existing item that are equal in a range of fields and then copy the value from budget to the new item. 

     

    If we test with budget, it could look like this in your gallery:

     

    If(IsBlank(ThisItem.Budget),Text(First(Filter(MyList, Title = ThisItem.Title && Month = ThisItem.Month)).Budget), ThisItem.Budget)

     

    This will first check if there is any value in the field on the new item, if not, it will filter the list for a similar item (in this case will compare Title and Month, but you can put in many more filters so you get the exact match) and put in the budget value. In case there is already a value in budget, it will just display that one 🙂

     

    Hope it works 🙂

  • cosmin89 Profile Picture
    27 on at

    @RuneBH It worked, thanks a lot!

  • RuneBH Profile Picture
    24 on at

    Great!  You're welcome 🙂

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 342 Super User 2026 Season 2

#2
M Bilal Khan Profile Picture

M Bilal Khan 258

#3
Mohsin Ali Profile Picture

Mohsin Ali 231

Last 30 days Overall leaderboard