# Action for adding album art automatically

**URL:** <https://community.mp3tag.de/t/action-for-adding-album-art-automatically/11904>\
**Category:** Support\
**Created:** [April 22, 2011, 1:30pm UTC](https://community.mp3tag.de/t/action-for-adding-album-art-automatically/11904 "2011-04-22T13:30:34Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![jimpalompa](https://community.mp3tag.de/user_avatar/community.mp3tag.de/jimpalompa/32/8732_2.png) [@jimpalompa](https://community.mp3tag.de/u/jimpalompa)\
**Post date:** [April 22, 2011, 1:30pm UTC](https://community.mp3tag.de/t/action-for-adding-album-art-automatically/11904/1 "2011-04-22T13:30:34Z")

</div>

I recently learned a little bit on changing filenames with mp3tag, to get [iTunes formated filenames](https://community.mp3tag.de/t/11841/1).

Now I would like to see if I could make an action for adding album art automatically as well.

Why would I like to do this?  
Well you see I have over 6000 albums, all with different album art dimensions. Doing it automatically would minimize both time and hdd writing.

Let me explain how I organize my album art:  
Every album has it's own folder. In every folder there can be up to 3 different sizes.  
My standard dimensions are 600px, 800px and 1000px. The 1000px is not used at the moment, it's just there for future use.

I name all my album art by this filename scheme:

**album-art-600px.jpg  
album-art-800px.jpg  
album-art-1000px.jpg**

if not available in 600px I instead have one of the following:

**album-art-500px.jpg  
album-art-400px.jpg  
album-art-300px.jpg**

So now let's get to it. The action I want to do is: If there is a **album-art-800px.jpg** available the action should change the album art to that one, if **not** it should choose **album-art-600px.jpg**. If however there isn't even a **album-art-600px.jpg** available it should choose either **album-art-500px.jpg** , **album-art-400px.jpg** or lastly **album-art-300px.jpg**

Can anyone point me into the right direction?

---

<div class="post-metadata">

**Author:** ![DetlevD](https://community.mp3tag.de/user_avatar/community.mp3tag.de/detlevd/32/123_2.png) [@DetlevD](https://community.mp3tag.de/u/DetlevD)\
**Post date:** [April 22, 2011, 1:49pm UTC](https://community.mp3tag.de/t/action-for-adding-album-art-automatically/11904/2 "2011-04-22T13:49:55Z")

</div>

> [@jimpalompa](#):
>
> ...The action I want to do is: If there is a **album-art-800px.jpg** available the action should change the album art to that one, if **not** it should choose **album-art-600px.jpg**. If however there isn't even a **album-art-600px.jpg** available it should choose either **album-art-500px.jpg** , **album-art-400px.jpg** or lastly **album-art-300px.jpg**  
> Can anyone point me into the right direction?

Begin Action Group **Test\_2011#20110422.jimpalompa.AddCover** 

Action #1  
_Actiontype 12:_ **Import cover image from file**  
_Formatstring for image filename:_ **album-art-300px.jpg**

 [X] Delete existing cover image 

Action #2  
_Actiontype 12:_ **Import cover image from file**  
_Formatstring for image filename:_ **album-art-400px.jpg**

 [X] Delete existing cover image 

Action #3  
_Actiontype 12:_ **Import cover image from file**  
_Formatstring for image filename:_ **album-art-500px.jpg**

 [X] Delete existing cover image 

Action #4  
_Actiontype 12:_ **Import cover image from file**  
_Formatstring for image filename:_ **album-art-600px.jpg**

 [X] Delete existing cover image 

Action #5  
_Actiontype 12:_ **Import cover image from file**  
_Formatstring for image filename:_ **album-art-800px.jpg**

 [X] Delete existing cover image 

End Action Group **Test\_2011#20110422.jimpalompa.AddCover** (5 Actions)

 

DD.20110422.1752.CEST

---

<div class="post-metadata">

**Author:** ![jimpalompa](https://community.mp3tag.de/user_avatar/community.mp3tag.de/jimpalompa/32/8732_2.png) [@jimpalompa](https://community.mp3tag.de/u/jimpalompa)\
**Post date:** [April 22, 2011, 2:00pm UTC](https://community.mp3tag.de/t/action-for-adding-album-art-automatically/11904/3 "2011-04-22T14:00:37Z")

</div>

Won't that affect the hdd writing, writing each album art if available, just to write and replace another one again?

I would also like to not get any error dialog right after the action is done, which this action does.

Is it not possible to use some sort of script for this action instead?

Thanks for the quick input!

---

<div class="post-metadata">

**Author:** ![DetlevD](https://community.mp3tag.de/user_avatar/community.mp3tag.de/detlevd/32/123_2.png) [@DetlevD](https://community.mp3tag.de/u/DetlevD)\
**Post date:** [April 22, 2011, 2:12pm UTC](https://community.mp3tag.de/t/action-for-adding-album-art-automatically/11904/4 "2011-04-22T14:12:56Z")

</div>

> [@jimpalompa](#):
>
> ... I would also like to not get any error dialog right after the action is done, which this action does. ...

This cover import action does not yield an error or warning message, when a file is not found.  
It simply says nothing, even when a picture image has been imported.

DD.20110422.1815.CEST

---

<div class="post-metadata">

**Author:** ![jimpalompa](https://community.mp3tag.de/user_avatar/community.mp3tag.de/jimpalompa/32/8732_2.png) [@jimpalompa](https://community.mp3tag.de/u/jimpalompa)\
**Post date:** [April 22, 2011, 2:16pm UTC](https://community.mp3tag.de/t/action-for-adding-album-art-automatically/11904/5 "2011-04-22T14:16:04Z")

</div>

But it gives me a dialog:

Import cover from file "album-art-300px.jpg": File D:\iTunes Media\Music\_NSYNC\_NSYNC\album-art-300px.jpg cannot be accessed.  
Import cover from file "album-art-400px.jpg": File D:\iTunes Media\Music\_NSYNC\_NSYNC\album-art-400px.jpg cannot be accessed.  
Import cover from file "album-art-500px.jpg": File D:\iTunes Media\Music\_NSYNC\_NSYNC\album-art-500px.jpg cannot be accessed.  
Import cover from file "album-art-800px.jpg": File D:\iTunes Media\Music\_NSYNC\_NSYNC\album-art-800px.jpg cannot be accessed.  
Import cover from file "album-art-300px.jpg": File D:\iTunes Media\Music\_NSYNC\_NSYNC\album-art-300px.jpg cannot be accessed.  
Import cover from file "album-art-400px.jpg": File D:\iTunes Media\Music\_NSYNC\_NSYNC\album-art-400px.jpg cannot be accessed.  
Import cover from file "album-art-500px.jpg": File D:\iTunes Media\Music\_NSYNC\_NSYNC\album-art-500px.jpg cannot be accessed.  
Import cover from file "album-art-800px.jpg": File D:\iTunes Media\Music\_NSYNC\_NSYNC\album-art-800px.jpg cannot be accessed.  
Import cover from file "album-art-300px.jpg": File D:\iTunes Media\Music\_NSYNC\_NSYNC\album-art-300px.jpg cannot be accessed.  
Import cover from file "album-art-400px.jpg": File D:\iTunes Media\Music\_NSYNC\_NSYNC\album-art-400px.jpg cannot be accessed.  
Import cover from file "album-art-500px.jpg": File D:\iTunes Media\Music\_NSYNC\_NSYNC\album-art-500px.jpg cannot be accessed.  
Import cover from file "album-art-800px.jpg": File D:\iTunes Media\Music\_NSYNC\_NSYNC\album-art-800px.jpg cannot be accessed.  
Import cover from file "album-art-300px.jpg": File D:\iTunes Media\Music\_NSYNC\_NSYNC\album-art-300px.jpg cannot be accessed.

etc.

---

<div class="post-metadata">

**Author:** ![DetlevD](https://community.mp3tag.de/user_avatar/community.mp3tag.de/detlevd/32/123_2.png) [@DetlevD](https://community.mp3tag.de/u/DetlevD)\
**Post date:** [April 22, 2011, 2:28pm UTC](https://community.mp3tag.de/t/action-for-adding-album-art-automatically/11904/6 "2011-04-22T14:28:07Z")

</div>

> [@jimpalompa](#):
>
> But it gives me a dialog: ...

Those error messages might have a different cause.  
Maybe a wrong path, perhaps no authorized to access or otherwise.  
Maybe switch off:  
Mp3tag/Tools/Options/Messages/At warnings from actions.

DD.20110422.1830.CEST

---

<div class="post-metadata">

**Author:** ![jimpalompa](https://community.mp3tag.de/user_avatar/community.mp3tag.de/jimpalompa/32/8732_2.png) [@jimpalompa](https://community.mp3tag.de/u/jimpalompa)\
**Post date:** [April 22, 2011, 2:47pm UTC](https://community.mp3tag.de/t/action-for-adding-album-art-automatically/11904/7 "2011-04-22T14:47:48Z")

</div>

Will the action not affect the hdd writing, in example if there is both album-art-600px.jpg and album-art-800px.jpg, will the action first write the 600px, then write the 800px and delete the old one?

Or will it just skip writing the 600px since there is 800px available?

---

<div class="post-metadata">

**Author:** ![DetlevD](https://community.mp3tag.de/user_avatar/community.mp3tag.de/detlevd/32/123_2.png) [@DetlevD](https://community.mp3tag.de/u/DetlevD)\
**Post date:** [April 22, 2011, 2:54pm UTC](https://community.mp3tag.de/t/action-for-adding-album-art-automatically/11904/8 "2011-04-22T14:54:15Z")

</div>

> [@jimpalompa](#):
>
> Will the action not affect the hdd writing, in example if there is both album-art-600px.jpg and album-art-800px.jpg, will the action first write the 600px, then write the 800px and delete the old one? Or will it just skip writing the 600px since there is 800px available?

The answer to this question is one of the mysteries of Mp3tag.  
Who cares?  
It is the only way to reach your goal.

DD.20110422.1855.CEST

---

<div class="post-metadata">

**Author:** ![jimpalompa](https://community.mp3tag.de/user_avatar/community.mp3tag.de/jimpalompa/32/8732_2.png) [@jimpalompa](https://community.mp3tag.de/u/jimpalompa)\
**Post date:** [April 22, 2011, 3:24pm UTC](https://community.mp3tag.de/t/action-for-adding-album-art-automatically/11904/9 "2011-04-22T15:24:32Z")

</div>

Well I was just wondering. When you're processing over 110000 files you like to minimize the writing.

I just thought there was a way to have some sort of script, like I did with the iTunes filename thing.

---

<div class="post-metadata">

**Author:** ![DetlevD](https://community.mp3tag.de/user_avatar/community.mp3tag.de/detlevd/32/123_2.png) [@DetlevD](https://community.mp3tag.de/u/DetlevD)\
**Post date:** [April 22, 2011, 3:42pm UTC](https://community.mp3tag.de/t/action-for-adding-album-art-automatically/11904/10 "2011-04-22T15:42:20Z")

</div>

> [@jimpalompa](#):
>
> Well I was just wondering. When you're processing over 110000 files you like to minimize the writing. I just thought there was a way to have some sort of script, like I did with the iTunes filename thing.

If you could name a function, which will do something like _'If there is a album-art-800px.jpg available'_, then there would be the chance to do some nested $if() or $if2() construct.

And ... if you care about the large number of image files to process, then you have to organize your work differently. Simply touch less files.  
Copy all the best sized images to a file with the same name. So you don't have the need to decide what image file version to fetch and additionally you can save many action calls.

DD.20110422.1944.CEST

---

<div class="post-metadata">

**Author:** ![dano](https://community.mp3tag.de/user_avatar/community.mp3tag.de/dano/32/6_2.png) [@dano](https://community.mp3tag.de/u/dano)\
**Post date:** [April 22, 2011, 4:03pm UTC](https://community.mp3tag.de/t/action-for-adding-album-art-automatically/11904/11 "2011-04-22T16:03:02Z")

</div>

Or try a little different approach:

First run only an action to import the _album-art-800px.jpg_ images.  
After that use the filter [F3] to hide all files that got the 800px covers. Use this filter string:  
%\_covers% IS ""

Now import only 600px images. After that refresh the file view [F5] so the files with the 600px covers also disappear.

Repeat till finished.

---

<div class="post-metadata">

**Author:** ![system](https://community.mp3tag.de/uploads/default/original/2X/c/ce7035d426cb755a7916793326d23b465222a407.png) [@system](https://community.mp3tag.de/u/system)\
**Post date:** [February 9, 2026, 12:23pm UTC](https://community.mp3tag.de/t/action-for-adding-album-art-automatically/11904/12 "2026-02-09T12:23:03Z")

</div>


