Click here to Skip to main content
15,889,403 members

Comments by kranthi.oru (Top 50 by date)

kranthi.oru 8-Oct-11 5:31am View    
if i copy above lines iam getting error what is name space for ManagementObjectSearcher Please tell me.
kranthi.oru 12-Sep-11 9:48am View    
how can i use it?
kranthi.oru 12-Sep-11 8:00am View    
that's ok but this chk is not added to windows application

How to add this chk(webcontrol checkboxlist) to windows form

this.Controls.Add(chk); it's become error with out adding runtime control to the form we can't see. for this what can i do?

Please help me.
kranthi.oru 12-Sep-11 7:26am View    
hi digimanus Please show my coding

CheckBoxList chk = new CheckBoxList();
chk.RepeatDirection = RepeatDirection.Horizontal;
chk.RepeatColumns = 5;
chk.Height = 100;
chk.Width = 800;
for (int i = 0; i < 32; i++)
{
chk.Items.Add("sample");

}
chk.Visible = true;
this.Controls.Add(chk);


I got checkboxlist but the last line in the coding
this.Controls.Add(chk); came error.




Error 1 The best overloaded method match for 'System.Windows.Forms.Control.ControlCollection.Add(System.Windows.Forms.Control)' has some invalid arguments


The web control is not added to my form
kranthi.oru 12-Sep-11 7:01am View    
Yes I add that namespace and reference also but that control is not came.
CheckBoxList chk = new CheckBoxList(); I write this code in run time but CheckBoxList not came.