Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Apps - Power Apps Experimental Features
Answered

PowerApp ParseJSON function - acces JSON key with hyphen

(0) ShareShare
ReportReport
Posted on by 2

Dear all,

 

I am struggling in using ParseJSON PowerApp function to access JSON key with hyphen charachter "-" (e.g. "en-EN").

 

Let us consider this example of JSON string that is retreived via HTTP call.

Let us also consider that such JSON string is stored into jsonString variable.

 

 

{
"description":{
"en-EN":"...",
...
}
}

 

 

 

When I try to access to the JSON key "en-EN" powerapp throws to me an error in the second line.

 

 

Set(jsonObject;ParseJSON(jsonString));;
Text(jsonObject.description.en-EN);;

 

 

 

error:

"

The argument type is invalid. one of the following values is expected: Number, Text, Boolean.

The name is invalid. "EN" not recognized.

"

 

Do you know how to access to any key having an hyphene symbol as "en-EN"?

 

Thanks.

Categories:
  • JorisdG Profile Picture
    on at
    Re: PowerApp ParseJSON function - acces JSON key with hyphen

    Just as an FYI, based on this and other feedback asking this same question, I've updated the docs for parsejson, working with json, and untyped object to mention using single quotes to access fields with otherwise non-valid identifier names.

  • Verified answer
    JorisdG Profile Picture
    on at
    Re: PowerApp ParseJSON function - acces JSON key with hyphen

    You can put the property name in single quotes for any special identifiers (for example JSON allows a property named 0 or special characters like you have).

     

    Text(jsonObject.description.'en-EN');

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

Michael Gernaey – Community Spotlight

We are honored to recognize Michael Gernaey as our June 2025 Community…

Congratulations to the May 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 Apps

#1
WarrenBelz Profile Picture

WarrenBelz 770 Most Valuable Professional

#2
stampcoin Profile Picture

stampcoin 494

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 399

Featured topics