Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default msgbox prompt when user selects data from combo box

Use the click event of the combobox if it is from the Control Toolbox
toolbar.

Regards,
Tom Ogilvy


"tjb" wrote in message
...
When a user selects data from a combo box, how can I have
a message box prompt or User Form pop up?

Once again I know this is an easy one but I'm still
learning VBA!



  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default msgbox prompt when user selects data from combo box

Continuing to assume the combobox if from the Control Toolbox Toolbar
It still has a click event found in the sheet module


In design mode, double click on the combobox and you should go to a code
module with something like

Private Sub Combobox1_Click()

End Sub

Put your code there.

---------------------
If the combobox is actually a dropdown box from the forms toolbar, you would
right click on it and select Assign Macro. then Assign the macro you want
to run to the dropdown box.

Regards,
Tom Ogilvy


"tjb" wrote in message
...
Thank you for your response.

The combo box is on the sheet itself, not on a user form,
what would I enter for a click event?


-----Original Message-----
Use the click event of the combobox if it is from the

Control Toolbox
toolbar.

Regards,
Tom Ogilvy


"tjb" wrote in message
...
When a user selects data from a combo box, how can I

have
a message box prompt or User Form pop up?

Once again I know this is an easy one but I'm still
learning VBA!



.



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 102
Default msgbox prompt when user selects data from combo box

Private Sub ComboBox1_Change()
MsgBox Prompt:="You have selected " & _
ComboBox1.Value, Buttons:=vbOKOnly
End Sub

I chose the change event over the click event, don't know if theirs a whole
lot of difference??

Dan E

"tjb" wrote in message
...
Thank you for your response.

The combo box is on the sheet itself, not on a user form,
what would I enter for a click event?


-----Original Message-----
Use the click event of the combobox if it is from the

Control Toolbox
toolbar.

Regards,
Tom Ogilvy


"tjb" wrote in message
...
When a user selects data from a combo box, how can I

have
a message box prompt or User Form pop up?

Once again I know this is an easy one but I'm still
learning VBA!



.



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default msgbox prompt when user selects data from combo box

If you allow a user to type an entry into the combobox, it fires on every
keystroke - that would be a difference.

Regards,
Tom Ogilvy

"Dan E" wrote in message
...
Private Sub ComboBox1_Change()
MsgBox Prompt:="You have selected " & _
ComboBox1.Value, Buttons:=vbOKOnly
End Sub

I chose the change event over the click event, don't know if theirs a

whole
lot of difference??

Dan E

"tjb" wrote in message
...
Thank you for your response.

The combo box is on the sheet itself, not on a user form,
what would I enter for a click event?


-----Original Message-----
Use the click event of the combobox if it is from the

Control Toolbox
toolbar.

Regards,
Tom Ogilvy


"tjb" wrote in message
...
When a user selects data from a combo box, how can I

have
a message box prompt or User Form pop up?

Once again I know this is an easy one but I'm still
learning VBA!


.





  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 102
Default msgbox prompt when user selects data from combo box

Yep, never noticed that till now, that does suck. Thanks for pointing that
out...

Dan E

"Tom Ogilvy" wrote in message
...
If you allow a user to type an entry into the combobox, it fires on every
keystroke - that would be a difference.

Regards,
Tom Ogilvy

"Dan E" wrote in message
...
Private Sub ComboBox1_Change()
MsgBox Prompt:="You have selected " & _
ComboBox1.Value, Buttons:=vbOKOnly
End Sub

I chose the change event over the click event, don't know if theirs a

whole
lot of difference??

Dan E

"tjb" wrote in message
...
Thank you for your response.

The combo box is on the sheet itself, not on a user form,
what would I enter for a click event?


-----Original Message-----
Use the click event of the combobox if it is from the
Control Toolbox
toolbar.

Regards,
Tom Ogilvy


"tjb" wrote in message
...
When a user selects data from a combo box, how can I
have
a message box prompt or User Form pop up?

Once again I know this is an easy one but I'm still
learning VBA!


.









  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default msgbox prompt when user selects data from combo box

Thanks but how do I get different messages for different
values?
-----Original Message-----
Yep, never noticed that till now, that does suck. Thanks

for pointing that
out...

Dan E

"Tom Ogilvy" wrote in message
...
If you allow a user to type an entry into the combobox,

it fires on every
keystroke - that would be a difference.

Regards,
Tom Ogilvy

"Dan E" wrote in

message
...
Private Sub ComboBox1_Change()
MsgBox Prompt:="You have selected " & _
ComboBox1.Value, Buttons:=vbOKOnly
End Sub

I chose the change event over the click event, don't

know if theirs a
whole
lot of difference??

Dan E

"tjb" wrote in message
...
Thank you for your response.

The combo box is on the sheet itself, not on a user

form,
what would I enter for a click event?


-----Original Message-----
Use the click event of the combobox if it is from

the
Control Toolbox
toolbar.

Regards,
Tom Ogilvy


"tjb" wrote in message
...
When a user selects data from a combo box, how

can I
have
a message box prompt or User Form pop up?

Once again I know this is an easy one but I'm

still
learning VBA!


.







.

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
Prompt user to input data (pop-up box) Shags Excel Discussion (Misc queries) 2 January 13th 09 06:05 AM
Need an input box when user selects a value in a drop down box Susan Excel Worksheet Functions 4 September 8th 08 06:14 PM
If prompt for user data Miree Excel Discussion (Misc queries) 0 August 19th 08 12:06 PM
VB - ignore a msgbox prompt Kevin Excel Discussion (Misc queries) 3 January 10th 08 11:47 AM
Wait for user to change data after msgbox ???? CanadianTrev Excel Discussion (Misc queries) 1 June 18th 05 08:27 PM


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

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"