J
johnmmcparland
I am trying to add controls (e.g. radio buttons, group boxes) to a
windows form in a method which I call from the constructor.
However, when I do things like;
RadioButton rb= new RadioButton();
....
rb.Location.X= 67;
this.Controls.Add(rb); // this is the Windows Form instance
I am told that;
"Cannot modify the return value of
'System.Window.Forms.Control.Locatoin' because it is not a variable"
I have tried to use CreateControl() but it doesn't seem to have any
effect.
If anyone knows how to do this please help asap
John
windows form in a method which I call from the constructor.
However, when I do things like;
RadioButton rb= new RadioButton();
....
rb.Location.X= 67;
this.Controls.Add(rb); // this is the Windows Form instance
I am told that;
"Cannot modify the return value of
'System.Window.Forms.Control.Locatoin' because it is not a variable"
I have tried to use CreateControl() but it doesn't seem to have any
effect.
If anyone knows how to do this please help asap
John