I have written a couple python tools in a python toolbox in ArcPro 2.9.
The tools I have written are make changes to all projects within given folder. During initial development, I used notebooks in arcpro and used the code:aprx = arcpy.mp.ArcGISProject("CURRENT") which worked. Once I converted over to an actual python tool/script, the code is changed to affect all projects, which also works (as long as I am out of an affected project).
So, right now I have to open an empty project (or at least one not within the targeted folder) to run the tool so that all projects within the targeted folder are affected. I would like to be able to open one of the projects within the folder and still have it affect it along with the others... is there a way to do this from the tool (not notebooks or python window)?