Skip to main content

Notifications

Power Apps - Power Apps Pro Dev & ISV
Suggested answer

Calling ThisItem Dynamically in PowerApps

Like (1) ShareShare
ReportReport
Posted on 12 Sep 2024 08:01:44 by 29
I am currently working on a Power Apps Page and in this, I have a subtitle in the gallery which has a text of ThisItem.Departments, where Departments is a column in the linked Dataverse table: 
 
Now, I am writing Departments myself in the formula bar. However, I want to know if there is a way where the user can type in the column name they want in the text box above (highlighted), which will then change the text of the subtitle 3. Ideally, I am also looking for a way if the text box could be a dropdown (since the dropdown control is not an option in the PowerApp page) but that's not the main focus for me at the moment. I am currently just looking to call input the formula in the text of Subtitle 3 something as ThisItem.FieldSearch.Value (I know this syntax is wrong, it's just to explain what I am ideally looking for). 
 
Thanks!
  • smital Profile Picture
    smital 29 on 13 Sep 2024 at 01:27:53
    Calling ThisItem Dynamically in PowerApps
    Thanks for the help. Since I want the user to have option to select the text for only a few of the records, I was thinking of the approach that I can create another Dataverse table, add in the column names I want the user to select and then insert a combo box for them to select the "mode" they want the subtitle to appear. 
     
    The main issue though is how do I change the formula ThisItem.ColumnName in such a way that instead of writing the ColumnName myself, it is something which is changed based on the value of the combo box. 
     
    Btw I love the idea of a help box, it'll definitely benefit the user! 
  • Suggested answer
    FLMike Profile Picture
    FLMike 27,286 on 12 Sep 2024 at 15:25:07
    Calling ThisItem Dynamically in PowerApps
    Hi,
     
    You would need to essentially have a Switch that listed all the possible variations of Columns, wit their output being changed to text (if its not already) And you would then have a Default (for the Switch) that would pick a specific column
     
    Then you could have a Text Input, where as they type, it would use the Switch to determine what they meant (field wise) and IF it matched any it would show that value, if not it would show the default.
     
    What I would do then is have a Help option, that would list all the "fields" they could type in.
     
    That's how I would do it.
     
    If this helps please mark as the answer.

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

End of Year Newsletter…

End of Year Community Newsletter…

Tuesday Tip #12 Start your Super User…

Welcome to a brand new series, Tuesday Tips…

Tuesday Tip #11 New Opportunities…

Welcome to a brand new series, Tuesday Tips…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 144,696

#2
RandyHayes Profile Picture

RandyHayes 76,287

#3
Pstork1 Profile Picture

Pstork1 64,456

Leaderboard
Loading started
Loading complete