Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 113
Default Create a "Send" button

I have created a form using Excel. I would like the people who fill out his
form to click a Submit This Form button at the top of his form and have
this button e-mail the form file to me (with the form file as an attachnemt
to the e-mail).



I need to know how to create a button in an Excel file, so that when you
click this button, it generates an e-mail addressed to a pre-specified
recipient (e-mail would be pre-addressed to me) with the completed form file
as an attachment to the e-mail.


I have a lot of experience working with Excel, so if possible, Id prefer to
do this using a hyperlink and the capabilities of Excel, without using Visual
Basic. Is there a way to do what I need to do using Excel?
If Visual Basic is the only way this can be done, can you walk me through
the process of creating a button (and help me write the macro language) to do
this? (I have very little experience with Visual Basic!)

Thank you so much for your help!

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 14
Default Create a "Send" button

On Oct 8, 4:51 pm, Leslie wrote:
I have created a form using Excel. I would like the people who fill out his
form to click a "Submit This Form" button at the top of his form and have
this button e-mail the form file to me (with the form file as an attachnemt
to the e-mail).

I need to know how to create a button in an Excel file, so that when you
click this button, it generates an e-mail addressed to a pre-specified
recipient (e-mail would be pre-addressed to me) with the completed form file
as an attachment to the e-mail.

I have a lot of experience working with Excel, so if possible, I'd prefer to
do this using a hyperlink and the capabilities of Excel, without using Visual
Basic. Is there a way to do what I need to do using Excel?
If Visual Basic is the only way this can be done, can you walk me through
the process of creating a button (and help me write the macro language) to do
this? (I have very little experience with Visual Basic!)

Thank you so much for your help!


Leslie,

Follow the link and you will be able to complete the task with no
problem.(not a walkthru though)

http://www.ozgrid.com/VBA/send-email.htm

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 14
Default Create a "Send" button

On Oct 8, 4:51 pm, Leslie wrote:
I have created a form using Excel. I would like the people who fill out his
form to click a "Submit This Form" button at the top of his form and have
this button e-mail the form file to me (with the form file as an attachnemt
to the e-mail).

I need to know how to create a button in an Excel file, so that when you
click this button, it generates an e-mail addressed to a pre-specified
recipient (e-mail would be pre-addressed to me) with the completed form file
as an attachment to the e-mail.

I have a lot of experience working with Excel, so if possible, I'd prefer to
do this using a hyperlink and the capabilities of Excel, without using Visual
Basic. Is there a way to do what I need to do using Excel?
If Visual Basic is the only way this can be done, can you walk me through
the process of creating a button (and help me write the macro language) to do
this? (I have very little experience with Visual Basic!)

Thank you so much for your help!


Try this:

open your workbook
do ALT f11
in your workbook do insert and click module
doble click on the module you inserted
copy/paste this code
Sub Mail_workbook_Outlook_1()
'Working in 2000-2007
'This example send the last saved version of the Activeworkbook
Dim OutApp As Object
Dim OutMail As Object



Set OutApp = CreateObject("Outlook.Application")
OutApp.Session.Logon
Set OutMail = OutApp.CreateItem(0)



On Error Resume Next
With OutMail
.To = "email here"
.CC = "email here"
.BCC = ""
.Subject = "Report"
.Body = "what will fill the body here"
.Attachments.Add ActiveWorkbook.FullName
'You can add other files also like this
'.Attachments.Add ("C:\test.txt")
.Display 'or use .Send
End With
On Error GoTo 0
Set OutMail = Nothing
Set OutApp = Nothing
End Sub

save
go to the worksheet
create a square figure as you would in drawing in excel
right click on it and click asign macro
choose the macro you created "Mail_workbook_Outlook_1"
now when you click the square you created it will run the macro. it
will open outlook and you send the page.

cheers

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 113
Default Create a "Send" button

Thank you. I'll try both of your suggestions!

"Sangel" wrote:

On Oct 8, 4:51 pm, Leslie wrote:
I have created a form using Excel. I would like the people who fill out his
form to click a "Submit This Form" button at the top of his form and have
this button e-mail the form file to me (with the form file as an attachnemt
to the e-mail).

I need to know how to create a button in an Excel file, so that when you
click this button, it generates an e-mail addressed to a pre-specified
recipient (e-mail would be pre-addressed to me) with the completed form file
as an attachment to the e-mail.

I have a lot of experience working with Excel, so if possible, I'd prefer to
do this using a hyperlink and the capabilities of Excel, without using Visual
Basic. Is there a way to do what I need to do using Excel?
If Visual Basic is the only way this can be done, can you walk me through
the process of creating a button (and help me write the macro language) to do
this? (I have very little experience with Visual Basic!)

Thank you so much for your help!


Try this:

open your workbook
do ALT f11
in your workbook do insert and click module
doble click on the module you inserted
copy/paste this code
Sub Mail_workbook_Outlook_1()
'Working in 2000-2007
'This example send the last saved version of the Activeworkbook
Dim OutApp As Object
Dim OutMail As Object



Set OutApp = CreateObject("Outlook.Application")
OutApp.Session.Logon
Set OutMail = OutApp.CreateItem(0)



On Error Resume Next
With OutMail
.To = "email here"
.CC = "email here"
.BCC = ""
.Subject = "Report"
.Body = "what will fill the body here"
.Attachments.Add ActiveWorkbook.FullName
'You can add other files also like this
'.Attachments.Add ("C:\test.txt")
.Display 'or use .Send
End With
On Error GoTo 0
Set OutMail = Nothing
Set OutApp = Nothing
End Sub

save
go to the worksheet
create a square figure as you would in drawing in excel
right click on it and click asign macro
choose the macro you created "Mail_workbook_Outlook_1"
now when you click the square you created it will run the macro. it
will open outlook and you send the page.

cheers


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Create a "Send" button Leslie Excel Discussion (Misc queries) 1 October 8th 07 11:51 PM
Create a "Send" button Leslie Excel Worksheet Functions 2 October 8th 07 11:09 PM
Signature missing when "send to" "mail recipient" Jim Tortorelli Excel Discussion (Misc queries) 2 September 21st 07 05:19 PM
Send emails through VBA but skip outlook "Yes" button [email protected] Excel Programming 4 August 28th 06 06:07 PM
create links to check boxes marked "good" fair"and "bad" pjb Excel Worksheet Functions 3 April 20th 06 02:17 AM


All times are GMT +1. The time now is 10:15 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright 2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"