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 / Update a solution caus...
Power Apps
Unanswered

Update a solution cause my power apps to fail to load the SharePoint lists on PROD

(0) ShareShare
ReportReport
Posted on by 1,809 Super User 2024 Season 1

I have 2 sharepoint sites:-

 

1) Dev

2) PROD

 

I have 2 power platform environments:-

1)Dev

2)PROD

 

I have a solution inside Dev environment which has 1 power apps + 50 power automate flows + 100 environment variables reference the sharepoint site,lists/libraries.

 

now when i finished working on the solution on Dev for the first time >> i export the solution as managed >> then i import the solution inside PROD using the Upgrade option. where the solution got imported, but the environment variables on PROD were referencing the Dev sharepoint site,lists & libraries. so i went to the PROD default solution and i updated the environment  variables to reference the PROD sharepoint site,lists& ;libraries. after that whenever i do a change on Dev >> i export the solution as managed >> import it inside RPOD using the Update option instead of Upgrade and things were working well for around 1 month.

But today i added 1 new environment variable on Dev which reference a new library >> i export the solution as usual >> import it using update option, the import process completed successfully, but when i accessed the power apps on PROD it showed "can not load/find list" on all the screens, so i checked the environment variables inside the defaut solution, and i find that they are referencing the Dev sharepoint site,list & libraries.. as follow:-

 

johnjohnPter_0-1717720612384.png

 

 

to fix this i did the following steps, which i did them mainly by chance:-

1) i went to the Dev solution >> right click on the power app >> add required objects , as follow:-

johnjohnPter_1-1717720732421.png

 

 

2) then i export the solution >> import it inside PROD using update option >> update the environment variables inside the default solution to reference the PROD >> publish all customization >> now i have the power apps working well.. so to avoid this in the future what caused the problem at first stage? and how it got fixed??any advice please?

 

Thanks

I have the same question (0)
  • Pstork1 Profile Picture
    68,697 Most Valuable Professional on at

    When you use environment variables it writes the value to a Dataverse database in that environment the first time you create the solution.  After you've established the values in the DEV database you need to remove the values from the solution, Publish customizations and then export the solution. When you import the solution into Production the environment variables will then be null and you'll be prompted to provide values for them.  That is the correct way to do it and keeps you from having to edit the values directly in production. If the values exist in production and the ones in the solution file are null then you won't be prompted for new values. But if the solution file has values in it then they will tend to overwrite the existing values in production. The key is to make sure you always remove the values BEFORE you export the solution.

  • johnjohnPter Profile Picture
    1,809 Super User 2024 Season 1 on at

    @Pstork1 but the Update option was working well for me, even if i do not remove the values of the environment variables on Dev,, but it failed last week only..

  • Verified answer
    Pstork1 Profile Picture
    68,697 Most Valuable Professional on at

    That's because you didn't make any changes to the environment variables in the solution since you did the first import. And as you said you needed to edit all the environment variables in Prod when you did the first import. You aren't doing it the way documentation specifies that you need to and that is why it happened. It should continue to work as it did at this point, until you add another environment variable or change a value in the future. If you do it as I described, which is the way its designed to work then you won't have that problem.  If you continue to do it the way you described you will continue to have issues.

  • johnjohnPter Profile Picture
    1,809 Super User 2024 Season 1 on at

    @Pstork1 has the option to remove the current value of the environment variables been replaced by a toggle as follow:-

     

    it use to be as follow:-

     

    johnjohnPter_0-1718382144628.png

     

    now it is :-

     

    johnjohnPter_1-1718382156795.png

     

  • Verified answer
    Pstork1 Profile Picture
    68,697 Most Valuable Professional on at

    Yes, that is a new setting that was previewed at Build a couple weeks ago. I wasn't aware that it was rolled out yet. The result is the same. Turn it off to export the solution with null values.

    image.png

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

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 333 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard