VB to C# fucntion list

  • Thread starter Thread starter news.austin.rr.com
  • Start date Start date
N

news.austin.rr.com

Hi

I need to find a resource that allows me to find what C# functions match VB
functions. For instance I need to create a vb type MsgBox with ok and cancel
in C#. C# has MessageBox but can this be used to get ok cancel button
results?

thanks
 
Try this:

MessageBox.Show("Message", "Title", MessageBoxButtons.OKCancel,
MessageBoxIcon.Question, MessageBoxDefaultButton.Button2);

rish
 
Thanks

How would this look in an if()


rish said:
Try this:

MessageBox.Show("Message", "Title", MessageBoxButtons.OKCancel,
MessageBoxIcon.Question, MessageBoxDefaultButton.Button2);

rish
 
DialogResult result;

result = MessageBox.Show("Message", "Title", MessageBoxButtons.OKCancel,
MessageBoxIcon.Question, MessageBoxDefaultButton.Button2);
if(result == DialogResult.OK)
{
// do the affirmative task
}
else
{
// do the negative task
}

rish
 
Back
Top