Click here to Skip to main content
15,885,903 members
Articles / Programming Languages / C#

Using Winamp input plugins for tagging audio files

Rate me:
Please Sign up or sign in to vote.
4.74/5 (9 votes)
21 Jun 2007CPOL5 min read 68.8K   456   30  
C# Interop with dynamic loaded plug-ins and function pointers
namespace OC.Winamp.Components
{
    partial class WinampTagger
    {
        /// <summary>
        /// Required designer variable.
        /// </summary>
        private System.ComponentModel.IContainer components = null;

        /// <summary>
        /// Clean up any resources being used.
        /// </summary>
        /// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
        protected override void Dispose(bool disposing)
        {
            if (disposing && (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()
        {
            System.Windows.Forms.Label lblArtist;
            System.Windows.Forms.Label lblAlbum;
            System.Windows.Forms.Label lblTitle;
            System.Windows.Forms.Label lblTrack;
            System.Windows.Forms.Label lblComment;
            System.Windows.Forms.Label lblLength;
            System.Windows.Forms.Label lblYear;
            System.Windows.Forms.Label lblGenre;
            this.txtArtist = new System.Windows.Forms.TextBox();
            this.txtAlbum = new System.Windows.Forms.TextBox();
            this.txtTitle = new System.Windows.Forms.TextBox();
            this.txtTrack = new System.Windows.Forms.TextBox();
            this.txtComment = new System.Windows.Forms.TextBox();
            this.lblFixed = new System.Windows.Forms.Label();
            this.txtYear = new System.Windows.Forms.TextBox();
            this.txtGenre = new System.Windows.Forms.TextBox();
            this.btnWrite = new System.Windows.Forms.Button();
            lblArtist = new System.Windows.Forms.Label();
            lblAlbum = new System.Windows.Forms.Label();
            lblTitle = new System.Windows.Forms.Label();
            lblTrack = new System.Windows.Forms.Label();
            lblComment = new System.Windows.Forms.Label();
            lblLength = new System.Windows.Forms.Label();
            lblYear = new System.Windows.Forms.Label();
            lblGenre = new System.Windows.Forms.Label();
            this.SuspendLayout();
            // 
            // lblArtist
            // 
            lblArtist.ForeColor = System.Drawing.SystemColors.GrayText;
            lblArtist.Location = new System.Drawing.Point(1, 3);
            lblArtist.Name = "lblArtist";
            lblArtist.Size = new System.Drawing.Size(57, 13);
            lblArtist.TabIndex = 8;
            lblArtist.Text = "Artist: ";
            lblArtist.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // lblAlbum
            // 
            lblAlbum.ForeColor = System.Drawing.SystemColors.GrayText;
            lblAlbum.Location = new System.Drawing.Point(1, 19);
            lblAlbum.Name = "lblAlbum";
            lblAlbum.Size = new System.Drawing.Size(57, 13);
            lblAlbum.TabIndex = 9;
            lblAlbum.Text = "Album: ";
            lblAlbum.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // lblTitle
            // 
            lblTitle.ForeColor = System.Drawing.SystemColors.GrayText;
            lblTitle.Location = new System.Drawing.Point(1, 35);
            lblTitle.Name = "lblTitle";
            lblTitle.Size = new System.Drawing.Size(57, 13);
            lblTitle.TabIndex = 10;
            lblTitle.Text = "Title: ";
            lblTitle.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // lblTrack
            // 
            lblTrack.ForeColor = System.Drawing.SystemColors.GrayText;
            lblTrack.Location = new System.Drawing.Point(1, 51);
            lblTrack.Name = "lblTrack";
            lblTrack.Size = new System.Drawing.Size(57, 13);
            lblTrack.TabIndex = 11;
            lblTrack.Text = "Track: ";
            lblTrack.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // lblComment
            // 
            lblComment.ForeColor = System.Drawing.SystemColors.GrayText;
            lblComment.Location = new System.Drawing.Point(1, 67);
            lblComment.Name = "lblComment";
            lblComment.Size = new System.Drawing.Size(57, 13);
            lblComment.TabIndex = 12;
            lblComment.Text = "Comment: ";
            lblComment.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // lblLength
            // 
            lblLength.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
            lblLength.ForeColor = System.Drawing.SystemColors.GrayText;
            lblLength.Location = new System.Drawing.Point(1, 83);
            lblLength.Name = "lblLength";
            lblLength.Size = new System.Drawing.Size(57, 13);
            lblLength.TabIndex = 13;
            lblLength.Text = "Length: ";
            lblLength.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // lblYear
            // 
            lblYear.ForeColor = System.Drawing.SystemColors.GrayText;
            lblYear.Location = new System.Drawing.Point(94, 49);
            lblYear.Name = "lblYear";
            lblYear.Size = new System.Drawing.Size(36, 18);
            lblYear.TabIndex = 14;
            lblYear.Text = "Year: ";
            lblYear.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // lblGenre
            // 
            lblGenre.ForeColor = System.Drawing.SystemColors.GrayText;
            lblGenre.Location = new System.Drawing.Point(160, 49);
            lblGenre.Name = "lblGenre";
            lblGenre.Size = new System.Drawing.Size(43, 18);
            lblGenre.TabIndex = 15;
            lblGenre.Text = "Genre: ";
            lblGenre.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // txtArtist
            // 
            this.txtArtist.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
                        | System.Windows.Forms.AnchorStyles.Right)));
            this.txtArtist.BorderStyle = System.Windows.Forms.BorderStyle.None;
            this.txtArtist.Location = new System.Drawing.Point(64, 3);
            this.txtArtist.Margin = new System.Windows.Forms.Padding(3, 0, 3, 0);
            this.txtArtist.Name = "txtArtist";
            this.txtArtist.ReadOnly = true;
            this.txtArtist.Size = new System.Drawing.Size(221, 13);
            this.txtArtist.TabIndex = 0;
            this.txtArtist.TextChanged += new System.EventHandler(this.txt_TextChanged);
            this.txtArtist.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txt_KeyDown);
            // 
            // txtAlbum
            // 
            this.txtAlbum.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
                        | System.Windows.Forms.AnchorStyles.Right)));
            this.txtAlbum.BorderStyle = System.Windows.Forms.BorderStyle.None;
            this.txtAlbum.Location = new System.Drawing.Point(64, 19);
            this.txtAlbum.Margin = new System.Windows.Forms.Padding(3, 0, 3, 0);
            this.txtAlbum.Name = "txtAlbum";
            this.txtAlbum.ReadOnly = true;
            this.txtAlbum.Size = new System.Drawing.Size(221, 13);
            this.txtAlbum.TabIndex = 1;
            this.txtAlbum.TextChanged += new System.EventHandler(this.txt_TextChanged);
            this.txtAlbum.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txt_KeyDown);
            // 
            // txtTitle
            // 
            this.txtTitle.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
                        | System.Windows.Forms.AnchorStyles.Right)));
            this.txtTitle.BorderStyle = System.Windows.Forms.BorderStyle.None;
            this.txtTitle.Location = new System.Drawing.Point(64, 35);
            this.txtTitle.Margin = new System.Windows.Forms.Padding(3, 0, 3, 0);
            this.txtTitle.Name = "txtTitle";
            this.txtTitle.ReadOnly = true;
            this.txtTitle.Size = new System.Drawing.Size(221, 13);
            this.txtTitle.TabIndex = 2;
            this.txtTitle.TextChanged += new System.EventHandler(this.txt_TextChanged);
            this.txtTitle.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txt_KeyDown);
            // 
            // txtTrack
            // 
            this.txtTrack.BorderStyle = System.Windows.Forms.BorderStyle.None;
            this.txtTrack.Location = new System.Drawing.Point(64, 51);
            this.txtTrack.Margin = new System.Windows.Forms.Padding(3, 0, 3, 0);
            this.txtTrack.MaxLength = 3;
            this.txtTrack.Name = "txtTrack";
            this.txtTrack.ReadOnly = true;
            this.txtTrack.Size = new System.Drawing.Size(21, 13);
            this.txtTrack.TabIndex = 3;
            this.txtTrack.TextChanged += new System.EventHandler(this.txt_TextChanged);
            this.txtTrack.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txt_KeyDown);
            // 
            // txtComment
            // 
            this.txtComment.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
                        | System.Windows.Forms.AnchorStyles.Left)
                        | System.Windows.Forms.AnchorStyles.Right)));
            this.txtComment.BorderStyle = System.Windows.Forms.BorderStyle.None;
            this.txtComment.Location = new System.Drawing.Point(64, 67);
            this.txtComment.Margin = new System.Windows.Forms.Padding(3, 0, 3, 0);
            this.txtComment.Multiline = true;
            this.txtComment.Name = "txtComment";
            this.txtComment.ReadOnly = true;
            this.txtComment.ScrollBars = System.Windows.Forms.ScrollBars.Vertical;
            this.txtComment.Size = new System.Drawing.Size(221, 13);
            this.txtComment.TabIndex = 6;
            this.txtComment.TextChanged += new System.EventHandler(this.txt_TextChanged);
            this.txtComment.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txtComment_KeyDown);
            // 
            // lblFixed
            // 
            this.lblFixed.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)
                        | System.Windows.Forms.AnchorStyles.Right)));
            this.lblFixed.BackColor = System.Drawing.Color.Transparent;
            this.lblFixed.Font = new System.Drawing.Font("Microsoft Sans Serif", 7F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.lblFixed.ForeColor = System.Drawing.SystemColors.WindowText;
            this.lblFixed.Location = new System.Drawing.Point(64, 83);
            this.lblFixed.Name = "lblFixed";
            this.lblFixed.Size = new System.Drawing.Size(221, 13);
            this.lblFixed.TabIndex = 16;
            this.lblFixed.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // txtYear
            // 
            this.txtYear.BorderStyle = System.Windows.Forms.BorderStyle.None;
            this.txtYear.Location = new System.Drawing.Point(127, 51);
            this.txtYear.Margin = new System.Windows.Forms.Padding(3, 0, 3, 0);
            this.txtYear.MaxLength = 4;
            this.txtYear.Name = "txtYear";
            this.txtYear.ReadOnly = true;
            this.txtYear.Size = new System.Drawing.Size(27, 13);
            this.txtYear.TabIndex = 4;
            this.txtYear.TextAlign = System.Windows.Forms.HorizontalAlignment.Center;
            this.txtYear.TextChanged += new System.EventHandler(this.txt_TextChanged);
            this.txtYear.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txt_KeyDown);
            // 
            // txtGenre
            // 
            this.txtGenre.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
                        | System.Windows.Forms.AnchorStyles.Right)));
            this.txtGenre.BorderStyle = System.Windows.Forms.BorderStyle.None;
            this.txtGenre.Location = new System.Drawing.Point(198, 51);
            this.txtGenre.Margin = new System.Windows.Forms.Padding(3, 0, 3, 0);
            this.txtGenre.Name = "txtGenre";
            this.txtGenre.ReadOnly = true;
            this.txtGenre.Size = new System.Drawing.Size(87, 13);
            this.txtGenre.TabIndex = 5;
            this.txtGenre.TextChanged += new System.EventHandler(this.txt_TextChanged);
            this.txtGenre.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txt_KeyDown);
            // 
            // btnWrite
            // 
            this.btnWrite.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
            this.btnWrite.Enabled = false;
            this.btnWrite.Font = new System.Drawing.Font("Microsoft Sans Serif", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Pixel, ((byte)(0)));
            this.btnWrite.Location = new System.Drawing.Point(240, 82);
            this.btnWrite.Name = "btnWrite";
            this.btnWrite.Size = new System.Drawing.Size(45, 18);
            this.btnWrite.TabIndex = 7;
            this.btnWrite.Text = "Write";
            this.btnWrite.TextAlign = System.Drawing.ContentAlignment.TopCenter;
            this.btnWrite.UseVisualStyleBackColor = true;
            this.btnWrite.Visible = false;
            this.btnWrite.Click += new System.EventHandler(this.btnWrite_Click);
            // 
            // WinampTagger
            // 
            this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
            this.Controls.Add(this.btnWrite);
            this.Controls.Add(this.txtGenre);
            this.Controls.Add(lblGenre);
            this.Controls.Add(this.txtYear);
            this.Controls.Add(lblYear);
            this.Controls.Add(this.lblFixed);
            this.Controls.Add(lblLength);
            this.Controls.Add(this.txtComment);
            this.Controls.Add(lblComment);
            this.Controls.Add(this.txtTrack);
            this.Controls.Add(lblTrack);
            this.Controls.Add(this.txtTitle);
            this.Controls.Add(lblTitle);
            this.Controls.Add(this.txtAlbum);
            this.Controls.Add(lblAlbum);
            this.Controls.Add(this.txtArtist);
            this.Controls.Add(lblArtist);
            this.DoubleBuffered = true;
            this.MinimumSize = new System.Drawing.Size(288, 102);
            this.Name = "WinampTagger";
            this.Size = new System.Drawing.Size(288, 102);
            this.Load += new System.EventHandler(this.WinampTagger_Load);
            this.ResumeLayout(false);
            this.PerformLayout();

        }

        #endregion

        private System.Windows.Forms.Label lblFixed;
        private System.Windows.Forms.TextBox txtArtist;
        private System.Windows.Forms.TextBox txtAlbum;
        private System.Windows.Forms.TextBox txtTitle;
        private System.Windows.Forms.TextBox txtTrack;
        private System.Windows.Forms.TextBox txtComment;
        private System.Windows.Forms.TextBox txtYear;
        private System.Windows.Forms.TextBox txtGenre;
        private System.Windows.Forms.Button btnWrite;
    }
}

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Germany Germany
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.

Comments and Discussions