I have a little silly problem and I was hoping you guys could join in with your experience.
I need a text box with the following (dynamic) data:
TEXT
TEXT
TEXT
TEXT
_______________________
Name: Amount:
Blah 3
Blahblah 10
_______________________
But the text inside the box is a problem. So far I am doing all this text with a StringBuildertitle SB, and in the end I set MyTextBox.Text= SB.ToString();
I set the title inside the field as follows:
SB.AppendLine("Name\t\Amount:");
I generate data inside the loop as follows:
SB.AppendLine(name + "\t\t" + amount);
But this does not exactly match my example! If the name is larger than the previous one, the amount will be displayed in a different place compared to the previous one.
Fx. eg:
TEXT
TEXT
TEXT
TEXT
__________________
Navn Antal:
SpecSaver 1
MadEyes 1
Gucci 1
__________________
: ? , .
:. .txt :
using(var text = new StreamWriter("textfile.txt", false))
{
text.Write(SB);
}
, . MyTextBox.Text.