Doubt with textbox

0

I'm trying to create a log screen using textbox in C# .

At certain points in the program, I'd like to insert a line in this textbox . Take the example:

Linha 1> Realizando inserção..
Linha 2> Dados inseridos..
Linha 3> Pedido Realizado.

I tried to do it like this:

txtBoxLog.Text = "Realizando inserção..\n";

But each line of this program, instead of inserting a new line in textbox , it deletes what is written and puts the new value.

Sincerely, Yves Fernandes

    
asked by anonymous 04.02.2016 / 20:09

1 answer

0

Is TextBox set to Multiline ? if yes just do it;

txtBoxLog.Text += "Realizando inserção..\n";

The assignment command += concatenates the current content with the previous content.

    
04.02.2016 / 21:29