Jul 1, 2003 #1 rahmanjan Programmer Joined Apr 13, 2003 Messages 180 Location AU hi all, I am trying to simply loop through all the textboxes in a from by the following code. But raises error> frmCds parentForm=new frmCds(); foreach (TextBox obj in parentForm) { obj.Text="test"; } regards,
hi all, I am trying to simply loop through all the textboxes in a from by the following code. But raises error> frmCds parentForm=new frmCds(); foreach (TextBox obj in parentForm) { obj.Text="test"; } regards,
Jul 1, 2003 #2 Craig0201 Technical User Joined Oct 11, 2000 Messages 1,261 Location GB And quite rightly..... You're looping all the objects on the form, not just the textboxes. Craig Upvote 0 Downvote
Jul 2, 2003 Thread starter #3 rahmanjan Programmer Joined Apr 13, 2003 Messages 180 Location AU so? how can i do it? Upvote 0 Downvote
Jul 2, 2003 #4 Craig0201 Technical User Joined Oct 11, 2000 Messages 1,261 Location GB Look up typeof in help Craig Upvote 0 Downvote
Jul 2, 2003 Thread starter #5 rahmanjan Programmer Joined Apr 13, 2003 Messages 180 Location AU thanks mate, But unfortunately my .net installation is not complate and my help file doesn't work ... ;( regards Upvote 0 Downvote
thanks mate, But unfortunately my .net installation is not complate and my help file doesn't work ... ;( regards