Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Pages - Power Apps Portals
Answered

Displaying the account name from contact entity

(0) ShareShare
ReportReport
Posted on by 45

Hello everyone! I am having trouble with displaying the  "Account" name from a Contact record on a Portal page. I've tried this a couple ways, and for the life of me I cannot figure out why I can't display the account name like i want to.

 

The reason I want to pull the Account Name, is I would like to filter/redirect based on the account. I have several PowerBI Reports that are in different workspaces based on client. I want to be able to say " If Account = "parentcustomerid, then display this PowerBI report"

 

But - I can't get the Account Name (parentcustomerid) to even display!

 

I've placed the following in a webpage, trying to just display the information. I've selected a couple fields from the Contact Entity to at least prove I am in the right area.

 

 

rgilreath_2-1595258420157.png

 

I've made sure that I have a contact with the Account filled in:

rgilreath_1-1595258389894.png

 

But, when I render the page - this is what I get:

rgilreath_0-1595258329512.png

It pulls the other information correctly (email, phone, etc), but I cannot get it to show the Company Name.

 

I've added an entity record to then profile page as well - which shows that the Account Name is filled in on the Profile (free text, but still) as well as the user has access to the Account in question and can View the record:

rgilreath_3-1595258656645.png

 

I've created an Entity Permission, which allows the Web Role to Read/Write to the Contact and Account entities

 

I am not sure where I am going wrong in displaying this information. Any assistance is greatly appreciated!

 

  • Zap174 Profile Picture
    163 on at
    Re: Displaying the account name from contact entity

    Hi sorry for the confusion. I was able to get rid of the page and nav pane by editing the javascript on the web page according to the documentation found here:Add a Power BI report or dashboard to a webpage in a portal - Power Apps | Microsoft Docs

     

    I would like to get rid of the border around the report, how would I go about this?

    Zap174_0-1646410331002.png

     

  • Zap174 Profile Picture
    163 on at
    Re: Displaying the account name from contact entity

    Hi @ragavanrajan 

    Thanks for the help. I got it working! One more question, I want to hide the page tab on the bottom of the report and the filter pane on the right side of the report. How would I go about that?

  • ragavanrajan Profile Picture
    7,036 Most Valuable Professional on at
    Re: Displaying the account name from contact entity

    Hi @Zap174 

     

    Worth changing the color of the text or try inspecting the element and see if the data presents

     

    Also, make sure you set the table permissions properly. 

     

    Hope it helps. 
    ------------

    If you like this post, give it a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users to find it.

  • Zap174 Profile Picture
    163 on at
    Re: Displaying the account name from contact entity

    Hi ragavanrajan,

    Thanks for the reply. When I paste the code into the code editor, it appears as such after I save it:

    Zap174_0-1645725367620.png

    Then, when browsing my website, the text appears like this, even when I am signed into an account:

    Zap174_1-1645725566235.png

     

    Any ideas?

     

     

  • ragavanrajan Profile Picture
    7,036 Most Valuable Professional on at
    Re: Displaying the account name from contact entity

    Hi @Zap174 

     

    In Portal studio: 

     

    1. Select your web page and click <source code> icon at the bottom right and paste in your liquid code along with HTML tag. For Example 

    <div>
    ParentAccountId: {{user.parentcustomerid.id}}
    ParentAccountName: {{user.parentcustomerid.name}}
    </div>

     

    Hope it helps. 
    ------------

    If you like this post, give it a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users to find it.

  • Zap174 Profile Picture
    163 on at
    Re: Displaying the account name from contact entity

    Hello! Where did you place the code to print the information for the current logged in user? Was it in the JSON of the web page? Could you show me what the source code looks like?

  • RyanGilreath Profile Picture
    45 on at
    Re: Displaying the account name from contact entity

    Thank you @OOlashyn - that is exactly what I was missing from reading through the documents.

     

    I appreciate your help and feedback!

  • Verified answer
    OOlashyn Profile Picture
    3,496 Most Valuable Professional on at
    Re: Displaying the account name from contact entity

    Hi @rgilreath,

     

    Explaining a bit answer from @hardikv - parentcustomerid is a lookup value which is returned in the liquid as Entity Reference object (find more in docs here). This object contains 3 properties - Id, Name and logical_name of the entity. That's why when you tried to just use parentcustomerid you see nothing as it is a complex object and cannot be just printed on the page.

  • H V Profile Picture
    1,510 on at
    Re: Displaying the account name from contact entity

    Hi @rgilreath

    Please try below code

     

    ParentAccountId: {{user.parentcustomerid.id}}
    ParentAccountName: {{user.parentcustomerid.name}}

     

     

    If this helps you, mark as a solution! 

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

Paul Stork – Community Spotlight

We are honored to recognize Paul Stork as our July 2025 Community…

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

Leaderboard > Power Pages

#1
Lucas001 Profile Picture

Lucas001 60 Super User 2025 Season 1

#2
Fubar Profile Picture

Fubar 55 Super User 2025 Season 1

#3
surya narayanan Profile Picture

surya narayanan 35