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

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Possibility to retrace...
Power Apps
Unanswered

Possibility to retrace the previous screen

(0) ShareShare
ReportReport
Posted on by 33

Hello folks!

 

In my application I would like to collect user feedback in which questions are asked. There is a central response screen, but two different ways to get there. I would like to record how the user got to the response screen. So, is there a way to trace back from which screen the user navigated to the response screen?

 

Thanks ahead!

Categories:
I have the same question (0)
  • Verified answer
    zmorek Profile Picture
    3,272 on at
    Re: Possibility to retrace the previous screen

    You can set a variable = Parent.Name. (SetvarWhatever,Parent.Name); Navigate(Screen). That will tell you the screen the user was on.

  • Dr-Gazlamp Profile Picture
    33 on at
    Re: Possibility to retrace the previous screen

    Hi @zmorek, thanks for your reply and suggestion. Could you please describe in a little more detail how exactly to proceed? Unfortunately, I only have basic knowledge.

  • zmorek Profile Picture
    3,272 on at
    Re: Possibility to retrace the previous screen

    I can try! I'm not sure what you need though - you said you needed a way to identify what screen a user came from, which we've got so far. Where do you want to store this data, in a SharePoint list?

  • Dr-Gazlamp Profile Picture
    33 on at
    Re: Possibility to retrace the previous screen

    @zmorek, Correct, I want to identify from which screen the user came from. The storage of the data at the end on a sharepoint list is not the problem at all, but rather how to get the information on which screen the user was before.

    When I navigate to the target screen (answer_screen) I set the variable "Parent.Name" in the OnSelect property of the navigate button: Set(myvar, Parent.Name)

     

    On the answer_screen I can now retrieve the value of the variable via a text label? How does this work?

  • zmorek Profile Picture
    3,272 on at
    Re: Possibility to retrace the previous screen

    Yes, you can set the Text() property of the label to myvar, which will display that information.

  • Dr-Gazlamp Profile Picture
    33 on at
    Re: Possibility to retrace the previous screen

    When setting the variable with Set(myvar, Parent.Name) I get the error message: "Incompatible type. Your formula can't be evaluated because the types of context variables aren't compatible with the types of values in other parts of your app." Why is that?

  • zmorek Profile Picture
    3,272 on at
    Re: Possibility to retrace the previous screen

    Are you setting your variable "myvar" elsewhere in the app? That's telling you that it's getting set to different types in multiple places (e.g. text vs number)

  • Dr-Gazlamp Profile Picture
    33 on at
    Re: Possibility to retrace the previous screen

    No, Im using it only once.

    But my navigate button is part of a gallery. I noticed when I set the variable outside of a gallery, then it works.

  • zmorek Profile Picture
    3,272 on at
    Re: Possibility to retrace the previous screen

    That's because when you use Parent.Name in a gallery, it's trying to get the name of the parent control (the gallery), which it can't do, rather than the name of the parent screen. 

     

    You can use the button in your gallery to select the button outside of the gallery, which will get you the name of the screen.

     

    Button in gallery OnSelect = Select(ButtonOutsideofGallery)

     

    Button out of gallery OnSelect = Set(myvar, Parent.Name)

  • Dr-Gazlamp Profile Picture
    33 on at
    Re: Possibility to retrace the previous screen

    Awesome! This little work around works perfectly, thanks a lot!

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 757 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 322 Super User 2025 Season 2

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 209 Super User 2025 Season 2

Last 30 days Overall leaderboard