Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 173
Default Does "Send" Have an Associated Event?

Is there an event associated with clicking on the "Send This Selection"
button when using EnvelopeVisible to send a selection from a spreadsheet?
I'd like to trigger some code from this button click but can't find an event
for it.
Will
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,123
Default Does "Send" Have an Associated Event?

Do you want to run your own code when you press the button
Do I understand you correct ?

Run the test macro one time

Sub test()
Dim Mycontrol As CommandBarControl
Set Mycontrol = Application.CommandBars("Standard").FindControl _
(ID:=3738, Recursive:=True)
Mycontrol.OnAction = ThisWorkbook.Name & "!mymacro"
End Sub

Sub mymacro()
MsgBox "Hi"
End Sub

Use this to reset

Mycontrol.OnAction = ThisWorkbook.Name & "!mymacro"


--
Regards Ron de Bruin
http://www.rondebruin.nl



"roadkill" wrote in message ...
Is there an event associated with clicking on the "Send This Selection"
button when using EnvelopeVisible to send a selection from a spreadsheet?
I'd like to trigger some code from this button click but can't find an event
for it.
Will



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 173
Default Does "Send" Have an Associated Event?

Ron

Whoops!
I guess my description of what I want to do wasn't quite complete. I want
to trigger my code after the email has been sent (I don't want to run my code
instead of the current action taken when the button is clicked).

Also, your code attaches "mymacro" to the Email button on the Standard
toolbar. I want it to trigger from the "Send this Selection" button on the
"envelope" that is created when you click the Email button on the Standard
toolbar, but after the email has been sent.

Can this be done?

Thanks,
Will

"Ron de Bruin" wrote:

Do you want to run your own code when you press the button
Do I understand you correct ?

Run the test macro one time

Sub test()
Dim Mycontrol As CommandBarControl
Set Mycontrol = Application.CommandBars("Standard").FindControl _
(ID:=3738, Recursive:=True)
Mycontrol.OnAction = ThisWorkbook.Name & "!mymacro"
End Sub

Sub mymacro()
MsgBox "Hi"
End Sub

Use this to reset

Mycontrol.OnAction = ThisWorkbook.Name & "!mymacro"


--
Regards Ron de Bruin
http://www.rondebruin.nl



"roadkill" wrote in message ...
Is there an event associated with clicking on the "Send This Selection"
button when using EnvelopeVisible to send a selection from a spreadsheet?
I'd like to trigger some code from this button click but can't find an event
for it.
Will




  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,123
Default Does "Send" Have an Associated Event?

I don't think this is possible with a few code lines

Note that the send button can have 3 options
Send Sheet
Send Selection
Send Chart

--
Regards Ron de Bruin
http://www.rondebruin.nl



"roadkill" wrote in message ...
Ron

Whoops!
I guess my description of what I want to do wasn't quite complete. I want
to trigger my code after the email has been sent (I don't want to run my code
instead of the current action taken when the button is clicked).

Also, your code attaches "mymacro" to the Email button on the Standard
toolbar. I want it to trigger from the "Send this Selection" button on the
"envelope" that is created when you click the Email button on the Standard
toolbar, but after the email has been sent.

Can this be done?

Thanks,
Will

"Ron de Bruin" wrote:

Do you want to run your own code when you press the button
Do I understand you correct ?

Run the test macro one time

Sub test()
Dim Mycontrol As CommandBarControl
Set Mycontrol = Application.CommandBars("Standard").FindControl _
(ID:=3738, Recursive:=True)
Mycontrol.OnAction = ThisWorkbook.Name & "!mymacro"
End Sub

Sub mymacro()
MsgBox "Hi"
End Sub

Use this to reset

Mycontrol.OnAction = ThisWorkbook.Name & "!mymacro"


--
Regards Ron de Bruin
http://www.rondebruin.nl



"roadkill" wrote in message ...
Is there an event associated with clicking on the "Send This Selection"
button when using EnvelopeVisible to send a selection from a spreadsheet?
I'd like to trigger some code from this button click but can't find an event
for it.
Will






  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 173
Default Does "Send" Have an Associated Event?

I was afraid of that but had to ask. I've implemented a less-than-desired
work around. Thanks for responding.
- Will

"Ron de Bruin" wrote:

I don't think this is possible with a few code lines

Note that the send button can have 3 options
Send Sheet
Send Selection
Send Chart

--
Regards Ron de Bruin
http://www.rondebruin.nl



"roadkill" wrote in message ...
Ron

Whoops!
I guess my description of what I want to do wasn't quite complete. I want
to trigger my code after the email has been sent (I don't want to run my code
instead of the current action taken when the button is clicked).

Also, your code attaches "mymacro" to the Email button on the Standard
toolbar. I want it to trigger from the "Send this Selection" button on the
"envelope" that is created when you click the Email button on the Standard
toolbar, but after the email has been sent.

Can this be done?

Thanks,
Will

"Ron de Bruin" wrote:

Do you want to run your own code when you press the button
Do I understand you correct ?

Run the test macro one time

Sub test()
Dim Mycontrol As CommandBarControl
Set Mycontrol = Application.CommandBars("Standard").FindControl _
(ID:=3738, Recursive:=True)
Mycontrol.OnAction = ThisWorkbook.Name & "!mymacro"
End Sub

Sub mymacro()
MsgBox "Hi"
End Sub

Use this to reset

Mycontrol.OnAction = ThisWorkbook.Name & "!mymacro"


--
Regards Ron de Bruin
http://www.rondebruin.nl



"roadkill" wrote in message ...
Is there an event associated with clicking on the "Send This Selection"
button when using EnvelopeVisible to send a selection from a spreadsheet?
I'd like to trigger some code from this button click but can't find an event
for it.
Will








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
Excel 2003 giving annoying "Send/Don't Send" error when closing BigDaddyCool Excel Discussion (Misc queries) 0 January 29th 10 02:31 AM
Excel - Golf - how to display "-2" as "2 Under" or "4"as "+4" or "4 Over" in a calculation cell Steve Kay Excel Discussion (Misc queries) 2 August 8th 08 01:54 AM
Signature missing when "send to" "mail recipient" Jim Tortorelli Excel Discussion (Misc queries) 2 September 21st 07 05:19 PM
change "true" and "false" to "availble" and "out of stock" inthestands Excel Worksheet Functions 2 July 19th 07 07:05 PM
Count occurences of "1"/"0" (or"TRUE"/"FALSE") in a row w. conditions in the next BCB New Users to Excel 7 May 13th 06 10:02 PM


All times are GMT +1. The time now is 11:59 PM.

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

About Us

"It's about Microsoft Excel"