msgbox

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi all,

Just a quick question...
does anyone know how i can include the value of a combobox into my message that appears in my messagebox?

i.e if my combobox contains USA, how do i write 'you are in the USA site' ??

thx
 
C# code:

string myMessage;
myMessage = "You are in the " + myComboBox.SelectedText + " site.";
MessageBox.Show(myMessage);

VB.Net code
Dim myMessage as String
myMessage = "You are in the " & myComboBox.SelectedText & " site."
MessageBox.Show(myMessage)

David
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top