how to close visdiff window from command line

Dear Matlabbers,
Does anyone know if it is possible/how to close the visdiff output/Comparison window from the command line?
I'd like the outputwindow to be opened for a couple of seconds and then automatically close it from the command line; simply not opening the window in the first place is not what I'm looking for.
So, e.g.:
visdiff(file1.txt, file2.txt)
* opens visdiff window/comparison result *
(Insert: some code to close comparison window from command line)
* visdiff window closes*
Thanks in advance!

2 commentaires

ABC DEF
ABC DEF le 16 Avr 2020
Modifié(e) : ABC DEF le 6 Mai 2020
Never mind, I've found the solution myself. For anyone for whom it may be of help:
desktop = com.mathworks.mde.desk.MLDesktop.getInstance();
desktop.closeGroup('Comparison');
XIN
XIN le 28 Juin 2022
VERY USEFUL!

Connectez-vous pour commenter.

Réponses (0)

Catégories

En savoir plus sur Creating, Deleting, and Querying Graphics Objects dans Centre d'aide et File Exchange

Question posée :

le 16 Avr 2020

Commenté :

XIN
le 28 Juin 2022

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by