Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 53
Default How can I branch from to

Private Sub CommandButton1_Click()

From here...

End Sub

TO

Private Sub Workbook_BeforeClose(Cancel As Boolean)

code here...

Application.Quit

End Sub

Thank's Ahead.
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 53
Default How can I branch from to

On Saturday, November 10, 2012 7:46:26 AM UTC-5, Bobby wrote:
Private Sub CommandButton1_Click()



From here...



End Sub


Sorry I found my answer.

Thisworkbook.close


TO



Private Sub Workbook_BeforeClose(Cancel As Boolean)



code here...



Application.Quit



End Sub



Thank's Ahead.


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 587
Default How can I branch from to

hi


Private Sub CommandButton1_Click()
ThisWorkbook.Close
End Sub

--
isabelle


Le 2012-11-10 07:46, Bobby a écrit :
Private Sub CommandButton1_Click()

From here...

End Sub

TO

Private Sub Workbook_BeforeClose(Cancel As Boolean)

code here...

Application.Quit

End Sub

Thank's Ahead.


  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 53
Default How can I branch from to

On Saturday, November 10, 2012 7:46:26 AM UTC-5, Bobby wrote:
Private Sub CommandButton1_Click()



From here...



End Sub



TO



Private Sub Workbook_BeforeClose(Cancel As Boolean)



code here...



Application.Quit



End Sub



Thank's Ahead.


Hi Isabelle,
could you be more explicit as per the how to branch I.E:
goto Workbook_BeforeClose
for example
  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 587
Default How can I branch from to

hi,


if you run the command
ThisWorkbook.Close
Workbook_BeforeClose event will automatically execute

--
isabelle


Le 2012-11-10 12:24, Bobby a écrit :
Hi Isabelle, could you be more explicit as per the how to branch I.E:
goto Workbook_BeforeClose for example




  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 53
Default How can I branch from to

On Saturday, November 10, 2012 3:09:55 PM UTC-5, isabelle wrote:
hi,





if you run the command

ThisWorkbook.Close

Workbook_BeforeClose event will automatically execute



--

isabelle





Le 2012-11-10 12:24, Bobby a �crit :

Hi Isabelle, could you be more explicit as per the how to branch I.E:


goto Workbook_BeforeClose for example


Hi Isabelle!
Thank you for your advice! Work's well.
  #7   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 53
Default How can I branch from to

On Saturday, November 10, 2012 7:46:26 AM UTC-5, Bobby wrote:
Private Sub CommandButton1_Click()



From here...



End Sub



TO



Private Sub Workbook_BeforeClose(Cancel As Boolean)



code here...



Application.Quit



End Sub



Thank's Ahead.


Hi Isabelle
I did try your suggestion but unfortunately it does not branch to my

Private Sub Workbook_BeforeClose(Cancel As Boolean)

Application.DisplayAlerts = False

Application.Quit

End Sub

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
Write a branch to another macro iashorty Excel Worksheet Functions 5 April 10th 08 01:29 PM
how do i create chart like branch-sector sales & collections Gnana Prasad Excel Discussion (Misc queries) 1 January 11th 08 08:00 AM
How can I contact branch Office in Tokyo, Japan? newbird New Users to Excel 0 May 21st 06 03:19 PM
How to branch? achidsey Excel Programming 1 September 18th 05 12:57 AM
Establish a Branch of Clayton College here in Malaysia Datuk Dr. Mat Lazim Excel Worksheet Functions 2 July 8th 05 11:32 PM


All times are GMT +1. The time now is 03:40 AM.

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"