hey...
how to do the message box that can show all the data out..without clicking many times..?
Means that i do one program in for loop.Let said i do 5 times looping. After I run the program, i dun need to clicking 5 times to show the result one by one. What i need is show all the result in One message box, so i no need to click so many times...

thanks for helping...

System.
System.Text.StringBuilder sb = new System.Text.StringBuilder();

for (int i = 1; i <= 10; i++)
  {
   sb.AppendLine(string.Format("Value : {0}", i));
  }
MessageBox.Show(sb.ToString());
commented: You are a great questiontranslator! +8

How to modify this code.. so that the result will show in one messageBox and no need click so many times..

                IDictionaryEnumerator enu = sortList.GetEnumerator();

                while (enu.MoveNext())
                {
                    MessageBox.Show(enu.Value.ToString(), enu.Key.ToString());
                }
commented: This question is redundant. Apply the same logic you were given in adatapost's post. +0

First construct a string sb in your while loop, just as adatapost pointed out.
Then call MessageBox.Show(sb) after the loop.

First construct a string sb in your while loop, just as adatapost pointed out.
Then call MessageBox.Show(sb) after the loop.

not really understand... can u explain in detail? thanks ya....

What do you not understand?

Let's say you have a problem with your car.
It is insufficient to say: " I have a problem.", "I do not understand." etc. etc.

Tell us more something like this: "I have a problem with my car, its four wheels are missing, can anyone help me to understand how I can fix that?" "Thanks for any help"

Also... please start naming your threads something relevant, other than "Help!" :)

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.