Those times you need to change connection references in 20 Flows and you go oh no! First in the solution in dev, create the new connection references or bring them into the solution.
Then, export the unmanaged solution to your local machine. Put the unmanaged solution file in a nice folder, I go for C:/temp as it’s shorter to type in the console later and is a transitory folder.
Go into VSC and open up a terminal. (First of course, install the PAC functions).
In the VSC shell, go to the temp folder by typing cd c:\temp and do a ls (list), and ensure your zip file is there. Now type :
pac solution unpack –zipfile .\MySolutionApp_1_0_0_1.zip
This will create a number of folders depending on the contents of the solution. The customizations.xml holds all the connection references in the solution, and the Workflows contains all the Flows.
So assuming we want to change a connection reference from one to another. There are two fields per connection to care about:
- The logical name : connectionReferenceLogicalName
- The Display Name : connectionreferencedisplayname
Do a ‘replace in files’ (CTRL+SHIFT+H) and put in the old connectionreferencelogicalname and the new. Both should be in Customization.xml if you had already created the new references in the solution.
Then remove the old references from customizations.xml if you wish.
Go into Solution.xml and increment the Version to the next one desired.
Close all the open files, and go back to the terminal, and type:
pac solution pack –zipfile .\MySolutionApp_1_0_0_2.zip
I prefer to put the contents in a new solution but you can overwrite the old by incrementing the version number. When done, remember to wipe the extracted contents of the temp folder.
Now go to make.powerapps.com and import in your solution.