By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,404 Members | 1,937 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,404 IT Pros & Developers. It's quick & easy.

Print contents of WindowsForms UserControl

P: 2
I have a win forms application (c#) that has a UserControl containing many labels and text boxes.
I want to select the labels and textboxes from that UserControl and print only the selected items When a Print command is issued.
Can anyone tell me how I can do that.

I am using the following code to get access to each of the controls,

Expand|Select|Wrap|Line Numbers
  1. foreach (Control ctrl in objCtrl.Controls)
  2. {
  3.  
  4. }
  5.  
Thanks in advance
Apr 19 '07 #1
Share this question for a faster answer!
Share on Google+

Post your reply

Sign in to post your reply or Sign up for a free account.