Page 1 of 1

Odd build error

Posted: Wed Oct 29, 2008 9:28 am
by wjstarck
This just started popping up when I try to build OD:

Error 1 'OpenDental.FormAnestheticMedsInventory.Dispose(bool)': no suitable method found to override C:\Users\wjs\Desktop\OD 6.2x\OpenDental\Forms\FormAnestheticMedsInventory.designer.cs 12 27 OpenDental

I've scoured the form in question with a fine-toothed comb and everything looks in order. Have I missed something obvious somewhere?

Re: Odd build error

Posted: Wed Oct 29, 2008 10:05 am
by jordansparks
Doesn't look familiar.

Re: Odd build error

Posted: Wed Oct 29, 2008 10:28 am
by wjstarck
Thanks. It's probably easier for me to remake the form. I'm guessing something may have gotten corrupted when I made it originally...

Re: Odd build error

Posted: Wed Oct 29, 2008 10:46 am
by jordansparks
So the error seems to indicate that you are missing the Dispose method in your designer. Did you look to see if it's there?

Re: Odd build error

Posted: Wed Oct 29, 2008 11:21 am
by wjstarck
Yes,it was, which is what was so odd...

Another strange thing is that if I do this

Code: Select all

 namespace OpenDental {
	
public partial class FormAnestheticMedsInventory:Form {

            private List<AnesthMed> listAnestheticMeds;           
            public FormAnestheticMedsInventory() {
            InitializeComponent();
            Lan.F(this);
		}


            private void FormAnestheticMedsInventory_Load(object sender, System.EventArgs e) {

            FillGrid();
            }
The ODGrid won't fill. But If I move the FillGrid() to the method above, it does....?

Code: Select all

namespace OpenDental {
	public partial class FormAnestheticMedsInventory:Form {

            private List<AnesthMed> listAnestheticMeds;
            public FormAnestheticMedsInventory() {
            InitializeComponent();
            Lan.F(this);
            FillGrid();

             }

            private void FormAnestheticMedsInventory_Load(object sender, System.EventArgs e) {

            }

Re: Odd build error

Posted: Wed Oct 29, 2008 11:52 am
by jordansparks
That seems reasonable. I never put it in the constructor.

Re: Odd build error

Posted: Wed Oct 29, 2008 12:07 pm
by wjstarck
OK, Thanks...

Re: Odd build error

Posted: Thu Oct 30, 2008 8:07 am
by wjstarck
I figured out why the FillGrid() wasn't loading properly.

When I made the form I copied the BasicTemplate *before* double clicking on the form in the designer to create the load event.

So, this statement

this.Load += new System.EventHandler(this.BasicTemplate_Load);

Was missing from the designer generated code in my form. Once I put that statement back in my form, FillGrid() works now from within the Load method.