Can You tell me how create raport in C# and how printing in C#?
Exactly, I want to know how add text to printing. I did:
PrintDocument testPrint = new PrintDocument();
PrintDialog dlgPrint = new PrintDialog();
dlgPrint .AllowSomePages = true;
dlgPrint .ShowHelp = true;
dlgPrint .Document = testPrint;
DialogResult result = dlgPrint .ShowDialog();
if (result==DialogResult.OK)
{
testPrint.Print();
}
When I write to file I have some rubbish, but when I print this I have nothing (OK).
So I want to know haw add for example text? Please simple.