当前位置:网站首页>Improve efficiency, take you to batch generate 100 ID photos with QR code

Improve efficiency, take you to batch generate 100 ID photos with QR code

2022-06-23 21:39:00 Drink coke in the middle of the night

The company's work card has been upgraded recently , Need to do more than a hundred people's work permits , Because the enterprise wechat QR code is added to the certificate , So it will be more troublesome , It takes time and effort to export one by one .

The designer asked me for help , It took me more than two hours to do it , I'm so tired , Is there a way to quickly export . Of course , As early as 17 I have done this in One click to generate certificate photo The job of , It's not difficult for me , But I still stepped on some pits , Here we will explain clearly the methods and misunderstandings .

Preparation stage

We use first PS Design the whole layout , Recommended size of drawing board 643×1056px, It should be noted that , Each variable requires a separate layer , The variables in the following figure are... On the horizontal line “ full name ”、“ department ”、“ Position ”、“ Job number ” And the bottom enterprise wechat QR code .

Preparing the database , The order is not required , But the necessary data should have , Try not to include other data in the file .

The image path here is the full path .

Then copy the contents of the table, including the variable name in the first row , Then copy to the new txt In file , Don't worry about alignment , The system will automatically detect tabs .

The other thing to say is , We have to ensure that the maximum length of the field does not exceed the designed board surface , Adjust the word spacing and size properly , So that all the contents can be fully displayed , Not covered .

Set a variable

Next we turn on PS, Click on “ Images ” - “ Variable ” - “ Definition ”, To define variables .

We are in the variables window , Select the layer where the variable is located , Then check it out. “ Text substitution ”, If it's a picture , Just choose “ Pixel replacement ”, Fill in the name as the variable name we set in the database .

Because pixel replacement can only replace Gridding Layer after ,  So before we define variables , The picture must be truncated , Otherwise, when setting , No variable type “ Pixel replacement ” The option to .

Import variable data group

After defining the variables one by one , You can import the database . Click on “ file ” - “ Import ” - “ Variable data group ” Enter the import data group operation .

Select the data file in the import option , And set the encoding type to “UTF-8”, The default setting will pop up a garbled error prompt .

Note that the following two check boxes need to be checked here , Avoid identification errors .

After importing successfully , Get into “ Images ” - “ Variable ” - “ Data sets ” Test whether the data is imported successfully . If it works , When we click the switch button , The contents of the data table below will change , If the content is wrong , There will be a corresponding prompt , For example, the image path cannot be found .

export file

Because all the documents are from psd The , We need to export all documents first psd file .  Click on “ file ” - “ export ” - “ Data group as file ” Perform batch export operation .

We need to set the storage location , Used to store exported data sets psd file .

Click OK , Wait for psd File generation .

For exported psd file , Click on “ file ” - “ Script ” - “ image processor ” Execute the operation of exporting pictures , Click Run after setting the path .

It should be noted that , The settings in the preferences require adjustment , It doesn't need to move .

Click on “ function ” after , Software opens automatically and continuously psd file , And save the picture for you , Do not proceed at this time PS Other operating , Just wait for the script to run .

print typesetting

Because we need to print ID photos of certain sizes , Recommended word Typesetting .

We build new word file , Adjust the paper orientation to The transverse , Adjust the margins to 1cm.

Then drag all the generated diagrams directly into the document , At this time, ten ID photos can be printed on one page , Resources are used efficiently .

The above is the tutorial of one click batch generation of company ID photos written by cola for you

原网站

版权声明
本文为[Drink coke in the middle of the night]所创,转载请带上原文链接,感谢
https://yzsam.com/2021/12/202112211948433916.html