r/CodingHelp • u/Eye-Itchy • Jan 30 '22
[C#] Method not working , I need some help figuring out why the method isn’t working ?
2
u/Eye-Itchy Jan 30 '22
EDIT: I realised that I went about this the completely wrong way , what I was trying to do was Disable components of the current form displayed after pressing a particular button
2
u/DrTuup Jan 30 '22
Try setting breakpoint and see if the function is actually called. Happy to further help you if needed. I work a lot with C# at school.
2
u/Eye-Itchy Jan 30 '22
It is not
2
1
u/sergiOO7 Jan 30 '22
Exactly you are creating a new form that is disabled, you should grab the event and disabled the frame from there.
0
1
0
u/TheDharkside Jan 30 '22
You’re instantiating a new frmGeoCalc and not showing that one, shouldn’t you disable the already running main form?
1
11
u/BlackEric Jan 30 '22 edited Jan 30 '22
Line 27. Your identifier, frm3D, is the same name as the form you’re trying to instantiate. Give the identifier a unique name. Also post the error.
Edit: You did the same thing with line 35.