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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Differing behaviour fo...
Power Apps
Unanswered

Differing behaviour for app in Studio to Published

(1) ShareShare
ReportReport
Posted on by
OK bear with me - this could be a long one...
 
I have a Model Driven App - with an embedded Canvas App. 
The Canvas App is the problem here, in that in the studio the functionality works, but when published it does not.
 
Background and app purpose:
 
So, what I am trying to do is use a dropdown field to change a search box lookup O365 connector.
 
The properties of the DropdownCanvas item are:
 
  Items: ["Company 1", "Company 2"]
  OnChange: Set(vCompany,DropdownCanvas1.Selected.Value);
 
I then have a People Picker collection (installed from catteam)
 
Items: 
  Switch(vCompany,
      "Company 1",DefaultUserCollection_C1,
      "Company 2",DefaultUserCollection_C2
  )
OnSearch:
Switch(vCompany,
    "Company 1",
        //Notify(Self.SearchText);
        Set(vInUse,"T");
        ClearCollect(
            UserCollection_C1,
            AddColumns(
                Filter(
                    Office365Users_C1.SearchUser(
                        {
                            searchTerm: Self.SearchText,
                            top: 500
                        }
                    ),
                    !IsBlank(JobTitle)
                    && AccountEnabled = true
                ),
                SuggestionImgUrl,
                Substitute(
                    JSON(
                        Office365Users_C1.UserPhotoV2(Id),
                        JSONFormat.IncludeBinaryData
                    ),
                    """",
                    ""
                ),
                SuggestionKey,
                Mail,
                SuggestionName,
                DisplayName,
                SuggestionRole,
                JobTitle
            )
        ),
    "Viridor",
        //Notify(Self.SearchText);
        Set(vInUse,"V");
        ClearCollect(
            UserCollection_C2,
            AddColumns(
                Filter(
                    Office365Users_C2.SearchUser(
                        {
                            searchTerm: Self.SearchText,
                            top: 500
                        }
                    ),
                    !IsBlank(JobTitle)
                    && AccountEnabled = true
                ),
                SuggestionImgUrl,
                Substitute(
                    JSON(
                        Office365Users_C2.UserPhotoV2(Id),
                        JSONFormat.IncludeBinaryData
                    ),
                    """",
                    ""
                ),
                SuggestionKey,
                Mail,
                SuggestionName,
                DisplayName,
                SuggestionRole,
                JobTitle
            )
        )
);
 
There are some other minor properties on the search but nothing major.
The idea is - based on the dropdown, use the relevant connector to lookup users from EAD.
 
This works - in Studio, change the dropdown and the relevant directory is searched.
When Published and run - only the first connector is used.
 
I have used tables to view the collections I am using to verify all this and its just not working as it should when published.
I feel like I am missing something simple...but cant see the woods for the trees if that makes sense?!
 
Any one feeling brave enough to help?
 
Thanks
Dan
I have the same question (0)

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 721 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 320 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard