using System; using System.Collections; using System.Diagnostics; namespace Apps4u.WinApp.Controls.Buttons { /// <summary> /// Summary description for a4uButtonGetFolder. /// </summary> public class a4uButtonGetFolder : Apps4u.WinApp.Controls.Buttons.a4uButton { public a4uButtonGetFolder() { this.Image = System.Drawing.Image.FromFile("c:\\MyImage.ico"); this.Text = ""; } } }~~Bonnie
>using System; >using System.ComponentModel; >using System.Collections; >using System.Diagnostics; > >namespace Apps4u.WinApp.Controls.Buttons >{ > /// <summary> > /// Summary description for a4uButtonGetFolder. > /// </summary> > public class a4uButtonGetFolder : Apps4u.WinApp.Controls.Buttons.a4uButton > { > public System.Windows.Forms.ImageList ButtonImageList; > public System.ComponentModel.IContainer components; > > public a4uButtonGetFolder(System.ComponentModel.IContainer container) > { > /// > /// Required for Windows.Forms Class Composition Designer support > /// > container.Add(this); > container.Add(this.ButtonImageList); > InitializeComponent(); > > // > // TODO: Add any constructor code after InitializeComponent call > // > } > > public a4uButtonGetFolder() > { > /// > /// Required for Windows.Forms Class Composition Designer support > /// > > InitializeComponent(); > // > // TODO: Add any constructor code after InitializeComponent call > // > } > > /// <summary> > /// Clean up any resources being used. > /// </summary> > protected override void Dispose( bool disposing ) > { > if( disposing ) > { > if(components != null) > { > components.Dispose(); > } > } > base.Dispose( disposing ); > } > > > #region Component Designer generated code > /// <summary> > /// Required method for Designer support - do not modify > /// the contents of this method with the code editor. > /// </summary> > private void InitializeComponent() > { > this.components = new System.ComponentModel.Container(); > System.Resources.ResourceManager resources = new System.Resources.ResourceManager(typeof(a4uButtonGetFolder)); > this.ButtonImageList = new System.Windows.Forms.ImageList(this.components); > // > // ButtonImageList > // > this.ButtonImageList.ImageSize = new System.Drawing.Size(16, 16); > this.ButtonImageList.ImageStream = ((System.Windows.Forms.ImageListStreamer)(resources.GetObject("ButtonImageList.ImageStream"))); > this.ButtonImageList.TransparentColor = System.Drawing.Color.Transparent; > > // > // Button Properties > // > this.ImageIndex = 0; > this.ImageList = this.ButtonImageList; > this.Text = ""; > } > #endregion > } >} > >