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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / String/text in column ...
Power Apps
Answered

String/text in column check fails with dynamic content

(0) ShareShare
ReportReport
Posted on by 165

For may App I'm running a language check in the OnStart property. It's checked if the user has saved a language, if not use the local language, if this is not supported use englisch. For Testing I just hardcoded gblLanguages as ["EN,"DE"] but if I take this values from a column I'm getting an type error when checking gblLanguage in gblLanguages. Using the code like this works:

 

Set(gblLanguages, ["DE","EN"]);

Set(
 gblLanguage,
 If(
 IsBlank(gblDBUser.language_setting),
 Upper(
 Left(
 Language(),
 2
 )
 ),
 gblDBUser.language_setting
 )
);

If(
 !(gblLanguage in gblLanguages),
 Set(
 gblLanguage,
 "EN"
 )
);

 

Using as single column virtual view instead doesn't work.

Set(gblLanguages, vw_languages);
//Also tried:
Set(gblLanguages, vw_languages.language);
Set(gblLanguages, ShowColumns(vw_languages, "language"));
ClearCollect(colLanguage, vw_Languages);
ClearCollect(colLanguage, vw_Languages.language);

 

Even when I'm explicit telling the column to check in. This error cascades down in my code to  point where gblLanguage is recognized as error instead of text. I tried ClearCollect, but this also did not work. I have absolutely no idea why. Maybe someone knows why this doesn't work or at least has a new input because I'm running out of ideas.

Categories:
I have the same question (0)
  • Verified answer
    dukatz Profile Picture
    165 on at

    The Problem was the usage of gblLanguages und gblLanguage on  different Screen. The code itself was correct but Power Apps throw an error because the code on a different Screen was not. Not so easy to find.

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 421 Most Valuable Professional

#2
11manish Profile Picture

11manish 153 Super User 2026 Season 2

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 116 Super User 2026 Season 2

Last 30 days Overall leaderboard