cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
PierreBreau
Regular Visitor

Set Language from DropDown on AppStart

I am building an app in power apps, I have a dropdown which toggle the language from French to English, this part works fine. My problem is when the app starts there is no language selected so all my labels for example are empty even tough the Dropdown is set to English. 

 

This is the OnChange code of my dropdown:

 

Set(gblSelectedLocal, ddlLanguage.SelectedText.Title); 
UpdateContext({gblSelectedLocal: ddlLanguage.SelectedText.Title}); 
lblSelectedGlobal.Text = gblSelectedLocal;

so I try adding this code to the OnStart of the app but nothing is happening. I also try setting up the glbSelectedLocal variable on start as well but it seems like the OnStart function does nothing. 

 

Anyone have a good way to approach this? I'm new to PowerApps as well. 

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
PowerAddict
Super User II
Super User II

@PierreBreau I just tested it out and it works fine. So I am curious as to why it isn't working for you. Can you try this code in the OnVisible of the screen where you have the dropdown? I want to first make sure that it works for you. 

 

---
If you like this reply, please give kudos (Thumbs Up). And if this solves your problem, please mark this reply as a solution by selecting Accept as Solution. This makes it easier for others to find answers to similar questions. 

 

Thanks!

Hardit Bhatia

Microsoft Business Applications MVP

Microsoft Certified Trainer MCT

Blog | Twitter | LinkedIn | Facebook | YouTube  |  Email

View solution in original post

2 REPLIES 2
PowerAddict
Super User II
Super User II

@PierreBreau I just tested it out and it works fine. So I am curious as to why it isn't working for you. Can you try this code in the OnVisible of the screen where you have the dropdown? I want to first make sure that it works for you. 

 

---
If you like this reply, please give kudos (Thumbs Up). And if this solves your problem, please mark this reply as a solution by selecting Accept as Solution. This makes it easier for others to find answers to similar questions. 

 

Thanks!

Hardit Bhatia

Microsoft Business Applications MVP

Microsoft Certified Trainer MCT

Blog | Twitter | LinkedIn | Facebook | YouTube  |  Email

View solution in original post

PierreBreau
Regular Visitor

I ended up creating a page with a language selection button. When the user click the button it set the variable and then bring them into the app. 

 

Sorry for the late reply on this and thanks for trying to help

Helpful resources

Announcements
User Groups Public Preview

Join us for our User Group Public Preview!

Power Apps User Groups are coming! Make sure you’re among the first to know when user groups go live for public preview.

Power Apps Community Call

Monthly Power Apps Community Call

Did you miss the call?? Check out the Power Apps Community Call here!

Power Platform ISV STudio

Power Platform ISV Studio

ISV Studio is the go-to Power Platform destination for ISV’s to monitor & manage applications post-AppSource publish.

Top Solution Authors
Top Kudoed Authors
Users online (36,448)