I have written a script that reminds me on refreshing flows and powerapps according to a specific time rule.
Now I wanted to create an Azure function that ran every week but I do get an error that the assembly "System.Windows.Forms" could not be found.
2022-07-27T03:56:34Z [Error] EXCEPTION: The following exception occurred while retrieving member "WithAuthority": "Could not load file or assembly 'System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'. The system cannot find the file specified."
I call the following cmdlet:
Add-PowerAppsAccount -Username $Credentials.UserName -Password $Credentials.Password
Is there any chance to make this run?