TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Bill Greer
NA
1
1.8k
I need a little help with C# PrintPreivew
Oct 1 2010 9:31 PM
I am new to C#.
I have the following in my form class:
private void btnPrintPackingSlip_Click(object sender, EventArgs e)
{
printPreviewDialog1.Document = printDocument1;
printPreviewDialog1.ShowDialog();
}
private void btnPrintPackingSlip(object sender, System.Drawing.Printing.PrintPageEventAr… e)
{
Font HeadingFont = new Font("Broadway BT", 48);
Font SmallerFont = new Font("Broadway BT", 14);
Bitmap bmp = new Bitmap("bombay.gif");
Brush brBlack = Brushes.Black;
Brush brRed = Brushes.Red;
//Draw image on document
e.Graphics.DrawImage(bmp, 20, 20);
}
My btnPrintPackingSlip causes a blank page in the print preview dialog, so it never reaches my btnPrintPackingSlip method. What do I have wrong?
Reply
Answers (
1
)
Class method authorization through configuration?
Drop down list in forview with using C# codes