6

I've stumbled upon a great plug-in called "Remove empty layers", developed by @Germán Carrillo.

I'm wondering if it's possible to use this plug-in in the Python Console.

1
  • Does this tool remove the empty Layers just from the project or also from disk? Commented Jan 25, 2023 at 12:13

1 Answer 1

12

Yes. It is possible using the following lines.

from RemoveEmptyLayers.removeemptylayers import RemoveEmptyLayers
remove = RemoveEmptyLayers(iface)
remove.run()

Please also check this answer to understand what all removeemptylayers phrases mean.

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.