![]() |
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 |
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 |
All times are GMT +1. The time now is 08:48 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com