Jump to content

Macro with exporting file function


Recommended Posts

Hi,

 

I would like to use the export function for files in a macro ( File -> Export ).

But Affinity then reports that this function is not supported in macros.
This is a pity, because it would simplify a lot of things for me.

My use case is, for example, that I rasterize images, resize them and then export them as PNG and close the document directly without saving. This could be done by one click on a macro, if all processes were supported 😉

I could take all this before (Adobe) and was done with one click. Now I can capture the raster and size, but I still have to export it by hand. This makes the closing process an additional single process, which would be unnecessary at this point.

It would be great, if this is supported again.
 

regards

Arne

Edited by Arne Drews
Link to comment
Share on other sites

Hi @Arne Drews,

Welcome to the forums :)

You're correct in terms that Macros do not support exporting - however you may be able to achieve this workflow using Macros and Batch processing.

6 hours ago, Arne Drews said:

My use case is, for example, that I rasterize images, resize them and then export them as PNG

Can you confirm for me, are all of your source images the same size? And are you always resizing to the same size?

Thanks in advance!

Link to comment
Share on other sites

Hi @Dan C

Thanks for welcome me. Nice to see that my english is understood by you 😁

 

Yes, you're right, all source images should be rasterized and resized to the same target size.

I thought about batch too, but to process about five images I decided that it's not the smartes way.

If you think I'm wrong, please let me know how I can do that with a batch?

 

Thanks for help!

😎

Link to comment
Share on other sites

12 hours ago, Arne Drews said:

If you think I'm wrong, please let me know how I can do that with a batch?

You first need to write the macro to operate on each file. If, as you say, all files are resized to the same dimensions, then that should not be a problem. The macro should be saved in a library file, (.afmacros).

Call up File > New Batch Job. You can enter the location of your source files, your output files and the output format. Note, however that the default output format is afphoto. I often forget to unselect this! You can also select one or more macros to apply from macro library files.

Let us know how you get on.

John

 

Windows 11, Affinity Photo 2.4.2 Designer 2.4.2 and Publisher 2.4.2 (mainly Photo).

CPU: Intel Core i5 8500 @ 3.00GHz. RAM: 32.0GB  DDR4 @ 1063MHz, Graphics: 2047MB NVIDIA GeForce GTX 1050

Link to comment
Share on other sites

3 hours ago, John Rostron said:

The macro should be saved in a library file, (.afmacros).

Shouldn't the macro be saved in the Library, rather than in a library file, if it is to be used in a Batch Job?

-- Walt
Designer, Photo, and Publisher V1 and V2 at latest retail and beta releases
PC:
    Desktop:  Windows 11 Pro 23H2, 64GB memory, AMD Ryzen 9 5900 12-Core @ 3.00 GHz, NVIDIA GeForce RTX 3090 

    Laptop:  Windows 11 Pro 23H2, 32GB memory, Intel Core i7-10750H @ 2.60GHz, Intel UHD Graphics Comet Lake GT2 and NVIDIA GeForce RTX 3070 Laptop GPU.
    Laptop 2: Windows 11 Pro 24H2,  16GB memory, Snapdragon(R) X Elite - X1E80100 - Qualcomm(R) Oryon(TM) 12 Core CPU 4.01 GHz, Qualcomm(R) Adreno(TM) X1-85 GPU
iPad:  iPad Pro M1, 12.9": iPadOS 18.1, Apple Pencil 2, Magic Keyboard 
Mac:  2023 M2 MacBook Air 15", 16GB memory, macOS Sequoia 15.0.1

Link to comment
Share on other sites

1 hour ago, walt.farrell said:

Shouldn't the macro be saved in the Library, rather than in a library file, if it is to be used in a Batch Job?

As far as I can recall, when I save a macro into a library file it goes into the Library. If I create a new entry into the Library (from the hamburger dropdown) it creates it in the Library.  I can then export this as an .afmacros file.

You are right, however, in that when selecting a macro for a batch job, it has to be in the Library. So you do not have to export it to use it in a batch.

Windows 11, Affinity Photo 2.4.2 Designer 2.4.2 and Publisher 2.4.2 (mainly Photo).

CPU: Intel Core i5 8500 @ 3.00GHz. RAM: 32.0GB  DDR4 @ 1063MHz, Graphics: 2047MB NVIDIA GeForce GTX 1050

Link to comment
Share on other sites

On 8/14/2020 at 9:25 AM, Arne Drews said:

My use case is, for example, that I rasterize images, resize them and then export them as PNG and close the document directly without saving.

I may have misunderstood but if the images are completed and you are only opening them in Photo to resize and save as png then this can be automated by a Batch Job

BatchResize.png

Microsoft Windows 11 Home, Intel i7-1360P 2.20 GHz, 32 GB RAM, 1TB SSD, Intel Iris Xe
Affinity Photo - 24/05/20, Affinity Publisher - 06/12/20, KTM Superduke - 27/09/10

Link to comment
Share on other sites

54 minutes ago, John Rostron said:

As far as I can recall, when I save a macro into a library file it goes into the Library. If I create a new entry into the Library (from the hamburger dropdown) it creates it in the Library.  I can then export this as an .afmacros file.

Right. From the Macro panel, you can (a) save it into the Library or (b) export it as a "single-macro" file, with extension .afmacro.

As you need it in the Library in order to use it, approach (a) of simply saving it into the library is the way to go :)

-- Walt
Designer, Photo, and Publisher V1 and V2 at latest retail and beta releases
PC:
    Desktop:  Windows 11 Pro 23H2, 64GB memory, AMD Ryzen 9 5900 12-Core @ 3.00 GHz, NVIDIA GeForce RTX 3090 

    Laptop:  Windows 11 Pro 23H2, 32GB memory, Intel Core i7-10750H @ 2.60GHz, Intel UHD Graphics Comet Lake GT2 and NVIDIA GeForce RTX 3070 Laptop GPU.
    Laptop 2: Windows 11 Pro 24H2,  16GB memory, Snapdragon(R) X Elite - X1E80100 - Qualcomm(R) Oryon(TM) 12 Core CPU 4.01 GHz, Qualcomm(R) Adreno(TM) X1-85 GPU
iPad:  iPad Pro M1, 12.9": iPadOS 18.1, Apple Pencil 2, Magic Keyboard 
Mac:  2023 M2 MacBook Air 15", 16GB memory, macOS Sequoia 15.0.1

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.