We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Simple Question on Required Form Designer Variable(s)

Whe creating a new UserControl or Form class, VStudio inserts a Container class instance variable named components and assigns it to null. As far as I can tell it is never used beyond that. The overridden Dispose method checks it, and if it is not null, calls components.Dispose(). Is this variable really needed by the designer? If so, what is it used for? Just curious... -Roy

1 Reply

AD Administrator Syncfusion Team August 30, 2002 06:17 PM UTC

Certain controls/components like ImageList has a overloaded constructor that will take a IComponents argument. For such components, the desginer will look for this "components" member in the Form and use that with the above constructor when generating code. Doesn't seem very elegant, does it? -Praveen

Loader.
Live Chat Icon For mobile
Up arrow icon