0

textBox1.Text = "4 Nuggets"; If i wanted to press that again it wont put it as a list instead it will replace it. How do i fix this?

1 Answers1

1

If you want to write like a list first you should make your textbox multiline. You may make it from the designer or with code at runtime. Just wrote make textbox multiline to the internet if you did not.

So if you have a textBox like this

=>4 Nuggets

and you want to add another line like

=>4 Nugget

=>2 Chicken

as like in the comments you should use +=, but to pass the next line you should use '\n'

So your code must be something like this.

    string newLine = //something;
    textBox1.Text += "'\n'" + newLine;

Or

     string newLine = //something;
     textBox1.Text = textBox1.Text + "'\n'" + 
     newLine;

If you need further assistance just wrote