Anonymous Email

longytravel

Board Regular
Joined
Aug 2, 2011
Messages
68
Hi Guys.

I have developed a fairly straightforward 'feedback form'

I send the sheet out to people who i have worked with so they can rate my performance it has drop down boxes 0 - 10 etc.

They then press a button and then it emails it back to me.

Is there anyway i can make it return the sheet back to anonymously in outlook - effectively i don't want to know who has provided the feedback

Any ideas??

Thanks
 

Excel Facts

Does the VLOOKUP table have to be sorted?
No! when you are using an exact match, the VLOOKUP table can be in any order. Best-selling items at the top is actually the best.
USe
Code:
Sub Email()
ActiveWorkbook.SendMail "YOUR E-MAIL ADDRESS"
End Sub
Then make sure you password protect your VBA project
 
Upvote 0
THanks!!

Your help is greatly recieved.

I have dug out the VBA (it was a while since i designed this/'borrowed' it!!

This is what i have

HTML:
Sub Mail_workbook_1()
'Working in 97-2010
    Dim wb As Workbook
    Dim I As Long
    Set wb = ActiveWorkbook
    If Val(Application.Version) >= 12 Then
        If wb.FileFormat = 51 And wb.HasVBProject = True Then
            MsgBox "There is VBA code in this xlsx file, there will" & vbNewLine & _
                   "be no VBA code in the file you send. Save the" & vbNewLine & _
                   "file first as xlsm and then try the macro again.", vbInformation
            Exit Sub
        End If
    End If
    On Error Resume Next
    For I = 1 To 3
        wb.SendMail "MY EMAIL ADDRESS IS HERE", _
                    "Stakeholder Feedback"
        If Err.Number = 0 Then Exit For
    Next I
    On Error GoTo 0
 
    MsgBox "Your Feedback Has Been Sent - Thank You"
 
    Application.DisplayFullScreen = False
 
    ThisWorkbook.Close savechanges:=False
 
End Sub

Where would your bit come into this?
Again, i just want to ensure that i cant see who has sent the feedback back

Thanks
 
Upvote 0
Umm, you already have it covered here.
This should send the E-Mail back to you, without opening Outlook.
Doesn't it do that ??

Code:
For I = 1 To 3
        wb.SendMail "MY EMAIL ADDRESS IS HERE", _
                    "Stakeholder Feedback"
        If Err.Number = 0 Then Exit For
    Next I
 
Upvote 0
Sorry Michael, i havent been very clear.

Yep, this does email it back to me and it works well

I just need a way of getting the feedback without knowing who it is from. So if i open Outlook i can see who it has been returned back by (it just shows as a normal email and an attachment) can i get outlook/excel to hide the name of the person sending the email??

If not, is there a different way of doing this? I just want to give the person giving the feedback the knowledge it will be sent without me knowing who has provided it

I have no idea how best to attack it

Thanks
 
Upvote 0
If you are using Outlook 2007 have a try with:

Rich (BB code):
.SentOnBehalfOfName = "MickeyMouse@disneyland.com"

This fills out the From field - You need to add an @ so Outlook doesn't come up with a dialog asking for a valid style address.
 
Upvote 0
Thanks.

I am new to all this - where would that go in the code above?

Also, i am using outlook and excel 2003........
 
Upvote 0
Sorry Michael, i havent been very clear.

Yep, this does email it back to me and it works well

I just need a way of getting the feedback without knowing who it is from. So if i open Outlook i can see who it has been returned back by (it just shows as a normal email and an attachment) can i get outlook/excel to hide the name of the person sending the email??

If not, is there a different way of doing this? I just want to give the person giving the feedback the knowledge it will be sent without me knowing who has provided it

I have no idea how best to attack it

Thanks

Hi,

I've been having a think about the best way to go about this and it occurred to me that if you could forward the email to yourself as soon as it came in (with no body text), and then permanently delete the original, you would end up with an e-mail that has been sent from yourself to yourself with an attachment and no trace of the original e-mail.

To do this I've set up a custom script in Outlook, that you can then run based on a rule.

Heres the code (UNTESTED):
Code:
[SIZE=2]Sub CustomRule_Forward(feedbackMail As MailItem)[/SIZE]
 
[SIZE=2]Dim forwardItem As MailItem[/SIZE]
[SIZE=2]Set forwardItem = feedbackMail.Forward[/SIZE]
 
[SIZE=2]forwardItem.Display[/SIZE]
 
[SIZE=2]'Add your e-mail to the recipients bit below[/SIZE]
[SIZE=2]forwardItem.Recipients.Add "YOUR E-MAIL GOES HERE"[/SIZE]
 
[SIZE=2]'Make a unique subject to distinguish it from the original e-mail[/SIZE]
[SIZE=2]forwardItem.Subject = "New Stakeholder Feedback - Sent By Rule"[/SIZE]
 
[SIZE=2]'Clear the body of all text[/SIZE]
[SIZE=2]forwardItem.Body = ""[/SIZE]
 
 
[SIZE=2]'Send the e-mail[/SIZE]
[SIZE=2]forwardItem.Send[/SIZE]
 
[SIZE=2]End Sub[/SIZE]

In Outlook go to Developer > Visual Basic and create a new Module and then paste this code into that module.
The code basically forwards the e-mail to the address provided (your e-mail) and makes the text of the e-mail blank.

Then you need to create a rule to trigger it.

I'd create a new rule based on something like the following criteria:

Conditions:
If the subject contains: "Stakeholder Feedback"
-- I'd try and make the subject in your code as unique as possible to avoid the rule running for any other e-mails

Actions:
Permanently Delete It
Run a script > select the script "CustomRule_Forward"

No exceptions to the rule (unless you can think of any there should be), and then finish the rule.

Now when an e-mail comes in with that particular subject, the script will run, deleting the original and sending you a new e-mail without the original address.

Hope this helps!
 
Upvote 0
Sorry if its Outlook 2003 it'll probably be under Tools > Macros > Visual Basic Editor not Developer > Visual Basic
 
Upvote 0

Forum statistics

Threads
1,225,072
Messages
6,182,695
Members
453,132
Latest member
nsnodgrass73

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