While copying a code snippet from some sites and pdf,docs line numbers are also getting copied.I have to omit those line numbers in my text editor manually always. Any better way so that line numbers won't be copied?
sash_kp, just a remark on your comment on my reply:
your question stated
"copying a code snippet from some sites and pdf,docs"
the most sites that contain code snippets are more to 'look' at , rather than to copy-paste and use. the best, where they do give you examples that are decently coded, are the official pages, which do come with the code in downloadable form (even a lot of not-so reliable sites offer the code in .java files)
from pdf and docs ... well, if you're working with an e-book, and you have bought it, no doubt the author has given you access to some space where you can download the code used.
if you don't, chances are you downloaded an illegal copy, but how am I to know?
For Each ctrl As Control In Me.Controls("pnlMainPanel").Controls
If ctrl.GetType Is GetType(System.Windows.Forms.Panel) Then
For Each subCtrl As Control In ctrl.Controls
If subCtrl.GetType Is GetType(System.Windows.Forms.TextBox) Then
If subCtrl.GetType Is ...