Closing the project from macro
Forum rules
If you require help using Audacity, please post on the forum board relevant to your operating system:
Windows
Mac OS X
GNU/Linux and Unix-like
If you require help using Audacity, please post on the forum board relevant to your operating system:
Windows
Mac OS X
GNU/Linux and Unix-like
Re: Closing the project from macro
Ok, thank you for an explanation.
I will try Python scripting.
But I think it would be helpful if somebody add to manual some words about Close command not suitable for macros.
I will try Python scripting.
But I think it would be helpful if somebody add to manual some words about Close command not suitable for macros.
Re: Closing the project from macro
Most people would probably not use the "Close" command because it isn't in the Macro Editor. If I recall correctly there's a few other commands that are excluded from the Macro Editor (because they are unsuitable for macros).
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)
-
- Forum Staff
- Posts: 14508
- Joined: Tue Jul 31, 2007 11:03 am
- Operating System: Windows 10
Re: Closing the project from macro
Which begs the question then: just how does one get a "Close" command in a Macro ?

Peter.
________________________________________FOR INSTANT HELP: (Click on Link below)
* * * * * FAQ * * * * * Tutorials * * * * * Audacity Manual * * * * *
* * * * * FAQ * * * * * Tutorials * * * * * Audacity Manual * * * * *
Re: Closing the project from macro
You would need to manually edit the macro's .txt file.waxcylinder wrote: ↑Wed Apr 07, 2021 3:28 pmWhich begs the question then: just how does one get a "Close" command in a Macro ?![]()
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)
Re: Closing the project from macro
I think the explanation Steve presented in this discussion is very useful for understanding how macros really work.
It will really help people if it would be added to manual.
It will really help people if it would be added to manual.
-
- Forum Staff
- Posts: 14508
- Joined: Tue Jul 31, 2007 11:03 am
- Operating System: Windows 10
Re: Closing the project from macro
So, which particular bit (or bits) that Steve wrote do you think would be useful in the Manual ?
Peter.
________________________________________FOR INSTANT HELP: (Click on Link below)
* * * * * FAQ * * * * * Tutorials * * * * * Audacity Manual * * * * *
* * * * * FAQ * * * * * Tutorials * * * * * Audacity Manual * * * * *
Re: Closing the project from macro
1. I would suggest adding following text in general article about macros:
The macro is running as the current project and cannot complete if the project is closed. So the "Close" command can't be used in the macro.
You can create a new project with a macro, but that macro can't do anything in the new project because it's a different project. When a macro runs, it is acting on the project in which it was opened.
2. Also it would help if some text will be added to the description of the interface of the Macro Editor, where batch file processing is explained:
Audacity allows to apply a macro to multiple audio files. Applying a macro to multiple Audacity projects can't be done with a macro, if you wish to do it, you need to use Python scripting.
3. It also won't hurt to add some direct explanation to the description of "Close" command:
"Close" command is excluded from the Macro Editor because it can't be used in the macro.
The macro is running as the current project and cannot complete if the project is closed. So the "Close" command can't be used in the macro.
You can create a new project with a macro, but that macro can't do anything in the new project because it's a different project. When a macro runs, it is acting on the project in which it was opened.
2. Also it would help if some text will be added to the description of the interface of the Macro Editor, where batch file processing is explained:
Audacity allows to apply a macro to multiple audio files. Applying a macro to multiple Audacity projects can't be done with a macro, if you wish to do it, you need to use Python scripting.
3. It also won't hurt to add some direct explanation to the description of "Close" command:
"Close" command is excluded from the Macro Editor because it can't be used in the macro.
-
- Forum Staff
- Posts: 14508
- Joined: Tue Jul 31, 2007 11:03 am
- Operating System: Windows 10
Re: Closing the project from macro
Yes, but there is no "Close" command available in Macros - it's only the clever uber-geek folk that play around with editing their Macros with a text editor and add in non-standard Macro commands. The Close was left out of the menu of commands available to Macro Manager on purpose.Msv264 wrote: ↑Fri Apr 09, 2021 9:39 pm1. I would suggest adding following text in general article about macros:
The macro is running as the current project and cannot complete if the project is closed. So the "Close" command can't be used in the macro.
You can create a new project with a macro, but that macro can't do anything in the new project because it's a different project. When a macro runs, it is acting on the project in which it was opened.
You might argue that the macro Manager or the Macro Palette should reject any Macro that has an "illegal" command like "Close" in it. But that would be an enhancement request.
The Manual is written on the basis the we expect folk to use the Macro Manager as their way of building Macros.
I can think about adding something along these lines - I have to make some changes anyway to the Macros pages as a result of fixing a recent bug.Msv264 wrote: ↑Fri Apr 09, 2021 9:39 pm2. Also it would help if some text will be added to the description of the interface of the Macro Editor, where batch file processing is explained:
Audacity allows to apply a macro to multiple audio files. Applying a macro to multiple Audacity projects can't be done with a macro, if you wish to do it, you need to use Python scripting.
I'm not convinced that this is necessary - but I will give it some thought.
@Steve: are there any other commands that are deliberately excluded for Macros Manager ?
Peter.
________________________________________FOR INSTANT HELP: (Click on Link below)
* * * * * FAQ * * * * * Tutorials * * * * * Audacity Manual * * * * *
* * * * * FAQ * * * * * Tutorials * * * * * Audacity Manual * * * * *
-
- Forum Staff
- Posts: 14508
- Joined: Tue Jul 31, 2007 11:03 am
- Operating System: Windows 10
Re: Closing the project from macro
Curiously I've just discovered that you can actually in 3.0.0 run Macros on 2.4.2 and earlier created older AUP files.waxcylinder wrote: ↑Sat Apr 10, 2021 11:12 amI can think about adding something along these lines - I have to make some changes anyway to the Macros pages as a result of fixing a recent bug.Msv264 wrote: ↑Fri Apr 09, 2021 9:39 pm2. Also it would help if some text will be added to the description of the interface of the Macro Editor, where batch file processing is explained:
Audacity allows to apply a macro to multiple audio files. Applying a macro to multiple Audacity projects can't be done with a macro, if you wish to do it, you need to use Python scripting.
This is because in 3.3.0 only File>Open can be used to open the new AUP3 projects.
BUT with the old AUP project files from 2.4.2 and earlier for some strange reason (I've forgotten why) the developer who worked on Unitary Project enabled File>Import as well as File>Open to operate on AUP files - and thus Macros can work on AUP project files because they can Import them.
I can see that it might be useful for Macros to work on AUP3 projects as well as older AUP ones - so I'll consider adding an ENH enhancement request for this.
Peter.
________________________________________FOR INSTANT HELP: (Click on Link below)
* * * * * FAQ * * * * * Tutorials * * * * * Audacity Manual * * * * *
* * * * * FAQ * * * * * Tutorials * * * * * Audacity Manual * * * * *
Re: Closing the project from macro
It may be worth noting on this page: https://alphamanual.audacityteam.org/ma ... _Referencewaxcylinder wrote: ↑Sat Apr 10, 2021 11:12 amYes, but there is no "Close" command available in Macros - it's only the clever uber-geek folk that play around with editing their Macros with a text editor and add in non-standard Macro commands. The Close was left out of the menu of commands available to Macro Manager on purpose.
in the Intro section, that a few commands are intentionally omitted from the Macro manager (such as "Close:") because they are unsuitable for use in macros.
(I'm not sure if we can update the manual at the moment or if we need to wait for Audacity 3.0.1 to be released).
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)