#1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 37
Default Exit Event

I have a situation something like this:

Sub Main()
UserForm1.Show
End Sub

UserForm1 has ComboBox1, ComboBox2, TextBox1, CommandButton1 and
CommandButton2.

In the code for UserForm, I have something like:

Private Sub TextBox1_Exit(ByVal Cancel As MSForms.ReturnBoolean)
MsgBox("Hi")
End Sub

When the code compiles, I get:

Compile error: Expected Function or variable

Can someone help me with this one?

TIA
Mike

--
Michael J. Malinsky



  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 37
Default Exit Event

Never mind...it seems I had another inadvertent error elsewhere in my code.
I swear it worked before I keyed in the Exit code.

Thanks anyway.

--
Michael J. Malinsky


"Michael J. Malinsky" wrote in message
...
I have a situation something like this:

Sub Main()
UserForm1.Show
End Sub

UserForm1 has ComboBox1, ComboBox2, TextBox1, CommandButton1 and
CommandButton2.

In the code for UserForm, I have something like:

Private Sub TextBox1_Exit(ByVal Cancel As MSForms.ReturnBoolean)
MsgBox("Hi")
End Sub

When the code compiles, I get:

Compile error: Expected Function or variable

Can someone help me with this one?

TIA
Mike

--
Michael J. Malinsky





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
Capture event when exit Column G zSplash Excel Discussion (Misc queries) 2 December 27th 04 05:28 PM
If a called sub exit, how to the caller exit right away? luvgreen[_4_] Excel Programming 4 February 24th 04 05:06 PM
MSForms.TextBox Exit event isn't available in Excel class mosule lacos Excel Programming 2 December 12th 03 10:12 AM
Control Exit event Fred Excel Programming 0 November 19th 03 12:59 AM
OnTime event not firing in Workbook_Open event procedure GingerTommy Excel Programming 0 September 24th 03 03:18 PM


All times are GMT +1. The time now is 09:01 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"