0

Hello, guys. I need your help. :o3
I want to create a MessageBox which may "communicate" with form. Actually, i need to communicate with form. It's a kind of backtraking and I want to display in more ways the solution.

void afisare()
{
    int dame = int.Parse(Dame.Text);
    afisari++;
    for (int i = 0; i < dame; i++)
        for (int j = 0; j < dame; j++)
                        if (S[i] == j)
                            M[i, j].BackgroundImage = dama;
//bla bla bla
//end here comes the MessageBox part
//.
//.
//.
//.

If i don't make that messagebox the program will display all ways. But I want in same time to make smt in Form.
Does anyone have any idea?

3
Contributors
2
Replies
28
Views
3 Years
Discussion Span
Last Post by ddanbe
0

use a Yes/No messagebox to interact with form

            DialogResult MSG = MessageBox.Show("Subtitle", "Title", MessageBoxButtons.YesNo);
            if (MSG == DialogResult.Yes)
            {
                //code
            }
            else if (MSG == DialogResult.No)
            {
                //code
            }
This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.