send pdf when i have a link and not if cell empty

danbitton

New Member
Joined
Aug 5, 2020
Messages
22
Office Version
  1. 2010
hello everyone! I would like to send emails automatically via excel. The files are from my desktop. I can send e-mails thanks to a macro only if I insert in the cell the pdf link.
1601891477734.png

I make a table so that the pdf links are created automatically. I have to send a file to everyone. No problem, this is the table of pdf1, it sends well.
1601891498160.png

As for the second pdf, sometimes I would like to send it to customers, and sometimes not, thanks to a column, or when the value is 1, I would like to add the pdf 2, and not send it if the value is 0.
1601891523444.png


in the cells of pdf2, I wrote this function ( function if, and concatener)( if append_pdf_2 = 0 I would like a blank ("")

1601891930908.png

it works when the value of the pdf2 is 1( it thus sends two files to the clients) but it does not work when there must be only one pdf( that is when the value is 0 in append_pdf_2)
Do you have a macro that allows me to correct this error?
here is the macro
1601892072159.png

I don’t know how to code
thank you very much!!
 

Excel Facts

How to calculate loan payments in Excel?
Use the PMT function: =PMT(5%/12,60,-25000) is for a $25,000 loan, 5% annual interest, 60 month loan.

Forum statistics

Threads
1,214,780
Messages
6,121,522
Members
449,037
Latest member
tmmotairi

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top