2
Answers

Printing / formatting question

Brad

Brad

18y
1.9k
1
Hello I am very new to c#.
I am trying to send the below code to a printer. I works, but I want to bold the labels (ie. Name ...) Any ideas how to format in a string?

writer.WriteLine("Name: " + rdr["uname"].ToString());
writer.WriteLine(
"Password: " + rdr["pass"].ToString());
writer.WriteLine(
"User Type: " + rdr["uType"].ToString());
writer.WriteLine(
"Notes: ");
writer.WriteLine(
"\t" + rdr["notes"].ToString());
writer.WriteLine(
"---------------------------");
writer.WriteLine(
"");

Also anyone know of a good place to fine info on printing in general in c#?

Answers (2)