Click to See Complete Forum and Search --> : send email from Excel caused PopUP
Iat
Apr 1st, 2004, 06:37 AM
Hi,
I have a VBA routine for Excel to send email using Outlook from the client where the macro is executed. Is there a way to bypass the popup especially from Win2000 asked whether I concur on having this email send out (I think it's a security thing).
Any helps would be greatly appreciated.
PhiL
RobDog888
Apr 1st, 2004, 11:45 AM
There is now easy way to get around the security popup. This
only gets tighter with each new version of Outlook One way
around it is to create an Outlook add-in and if this is just for your
workstation, the you can create a digital signature for it and
make it trusted.
HTH
Iat
Apr 1st, 2004, 01:58 PM
this is just for my workstation, can you direct me on how to create a digital signature and make it trusted so I can send email from my vba ?
Thanks,
PhiL
RobDog888
Apr 1st, 2004, 02:46 PM
For Office 2003:
D:\Program Files\Microsoft Office\OFFICE11\SELFCERT.EXE
For XP:
D:\Program Files\Microsoft Office\Office10\SELFCERT.EXE
etc.
Run the program and follow the simple steps. It will create the
digital signature or certificate for vba projects.
Then in the VBA editor click Tools > Digital Signature... and click
Choose button and select the certificate you just created.
This will attach the signature to the project.
You can also set the security on Excel to High - only signed macros
from trusted sources will be run.
So only your macros will run.
Iat
Apr 1st, 2004, 07:14 PM
Hi,
I followed every step and got my Self Certificate created. I created the name to match my email address, to match my email name, my logon name but none of those CERTs make any different when I add it one at a time on the VBA editor => Tools, digital cert... when I ran the Macro and it attempt to send myself an email and there goes the PopUp again
RobDog888
Apr 1st, 2004, 10:22 PM
Since you are using two Office applications and Excel is trying to
execute the sending of email, you will need to create the VBA
project in Outlook, not in Excel. Then sign the project in Outlook.
To have Outlook trust emailing, the signature VBA needs to be in
Outlook.
HTH
RobDog888
Apr 1st, 2004, 11:09 PM
Oh ya, I almost forget. You also need to Import your certificate to
the "Trusted Root Certification Authorities store".
markf
Apr 3rd, 2004, 11:01 AM
Just to post a different option to the above, see the Thread: Emailing A Workbook - Can't get code to work
www.vbforums.com/showthread.php?s=&threadid=282579
With this there is no MAPI, and thus no Outlook Security warning anymore, but neither is a copy saved in your Mailbox, nor are the CDONTS/CDOSYS/CDOEX email components portable across all Windows versions, and none are supported in Windows 9x.
If you find that Thread useful you may want to add a bogus post to stop it dropping off the Forum. I am sure RobDog888 & Co's guidance will work OK.
Iat
Apr 3rd, 2004, 01:21 PM
Thanks I will post.
RobDog888
Apr 3rd, 2004, 08:42 PM
Were you not able to get the digital signature to work for you?
Iat
Apr 3rd, 2004, 09:47 PM
"Since you are using two Office applications and Excel is trying to
execute the sending of email, you will need to create the VBA
project in Outlook, not in Excel. Then sign the project in Outlook.
To have Outlook trust emailing, the signature VBA needs to be in
Outlook."
You asked me to create the VBA project in Outlook, not in Excel. But I must have my VBA done in Excel andthen send an email from within Excel to my inbox.
"Oh ya, I almost forget. You also need to Import your certificate to the "Trusted Root Certification Authorities store"."
then this post, really lost me. So, what I ended up doing, I removed the Office2000 and reinstalled. Although it still exhibits as SP3 but the email send fine from within Excel. I 'd love to know how to use the digital certificate but I am new to certificate on PC.
Thanks,
RobDog888
Apr 3rd, 2004, 11:40 PM
To make you Digital Signature Certificate "Trusted"...
Export the D.S.
After you create your D.S. view it like when you assign the D.S. to
your VBA project - Tools > Digital Signature > Choose... > Select
your certificate > View Certificate > Details Tab > Copy to file...
Then you will see the Certificate Export wizard. Click Next > Next
> Next > Browse to where you want to save it to (*.cer) > Next >
Finish.
Import the certificate
Browse to where you exported the certificate to and double click
it and wait for it to display the certificate. Then click Install
Certificate... > Next > Select "Place certificate in the following
store." and browse to "Trusted Root Certification Authorities" >
Next > Finish > Yes. Then your done.
Then check your VBA project's Digital Signature and it should
show that it is now "Trusted". If not, remove the Digital Signature
and then re-attach it to your VBA project again. You will no longer
see the little red circle x next to the certificate name.
This is good stuff, maybe I should code bank it?
:)
Iat
Apr 4th, 2004, 07:12 AM
Thank you for providing the detail instruction.
Here is what I did:
1) Create another D.S.
2) assign the D.S. to my VBA (Excel)
3) export the D.S.
4) successfully imported the D.S. to my VBA as you indicated, the red X mark is no longer there.
5) Execute my VBA
Despite all that, I am still getting the Outlook popup.
RobDog888
Apr 4th, 2004, 03:39 PM
You are probably getting the popup because your code is in Excel
and the ds does not cross office applications. Another idea is to
create a COM Add-In, but I haven't done one for two applications
in the same add-in. Maybe the add-in for Excel can execute the
add-in for Outlook? I remember reading that you can create a
single add-in for all of the office suite programs. This is what you
may need. Try searching M$ for more on this.
Sorry I don't have more info on this for you.
HTH
Iat
Apr 6th, 2004, 07:03 PM
Thanks RobDog888. I will live with the downgrade of my office2000 to avoid the Outlook Popup. If you ever know of a solution, please post.
Thanks again,
PhiL
reginaldm
Apr 7th, 2004, 08:01 AM
Try looking at this... http://www.dimastr.com/redemption/ It is a control that will allow you to create and send e-mails without seeing the message.
RobDog888
Apr 7th, 2004, 02:55 PM
Looks good, but @ $199.00 I think I can code around the
limitations like by using CDO or SMTP. Also, its slower and its not
exaclty the same as using the OOM properties directly, can't get
to the htmlbody property just the rtfbody prop.
vbforums.com
Copyright Internet.com Inc., All Rights Reserved.