folder Tahribat.com Forumları
linefolder C#, Asp.Net, .Net Core
linefolder C#'Ta Mp3 Çalma Olayı Kodları



C#'Ta Mp3 Çalma Olayı Kodları

  1. KısayolKısayol reportŞikayet pmÖzel Mesaj
    S1b3r_HasTa
    S1b3r_HasTa's avatar
    Kayıt Tarihi: 16/Temmuz/2005
    Erkek

    indexini textboxlarınızı ve butonlarınızı kodlardan rahatça çıkarabilirsiniz design kısmı için

    kodların tamamı bana aittir 8 sene önce yazdığım kodlardır internette çokca dolanmıştır bir dönem, nostalji olsun c#'a yeni başlayanlar içinde iyidir sormak istediğiniz şeyler varsada cevaplarım

     

    using System;

    using System.Drawing;

    using System.Collections;

    using System.ComponentModel;

    using System.Windows.Forms;

    using System.Data;

    using WMPLauncher;

    using WMPLib;

     

    namespace WindowsApplication1

    {

        /// <summary>

        /// Summary description for Form1.

        /// </summary>

        public class Form1 : System.Windows.Forms.Form

        {

            private System.Windows.Forms.Button button1;

            private System.Windows.Forms.MainMenu mainMenu1;

            private System.Windows.Forms.MenuItem menuItem1;

            private System.Windows.Forms.MenuItem menuItem2;

            private System.Windows.Forms.MenuItem menuItem3;

            private System.Windows.Forms.MenuItem menuItem4;

            private System.Windows.Forms.MenuItem menuItem5;

            private System.Windows.Forms.MenuItem menuItem6;

            private System.Windows.Forms.MenuItem menuItem7;

            /// <summary>

            /// Required designer variable.

            /// </summary>

            private System.ComponentModel.Container components = null;

     

            public Form1()

            {

                //

                // Required for Windows Form 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 Windows Form 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.Resources.ResourceManager resources = new System.Resources.ResourceManager(typeof(Form1));

                this.button1 = new System.Windows.Forms.Button();

                this.mainMenu1 = new System.Windows.Forms.MainMenu();

                this.menuItem1 = new System.Windows.Forms.MenuItem();

                this.menuItem2 = new System.Windows.Forms.MenuItem();

                this.menuItem3 = new System.Windows.Forms.MenuItem();

                this.menuItem4 = new System.Windows.Forms.MenuItem();

                this.menuItem5 = new System.Windows.Forms.MenuItem();

                this.menuItem6 = new System.Windows.Forms.MenuItem();

                this.menuItem7 = new System.Windows.Forms.MenuItem();

                this.SuspendLayout();

                // 

                // button1

                // 

                this.button1.Font = new System.Drawing.Font("Microsoft Sans Serif", 13F, ((System.Drawing.FontStyle)((System.Drawing.FontSt    yle.Bold | System.Drawing.FontStyle.Italic))), System.Drawing.GraphicsUnit.Point, ((System.Byte)(162)));

                this.button1.ForeColor = System.Drawing.Color.Brown;

                this.button1.Image = ((System.Drawing.Image)(resources.GetObject("button1.Image")));

                this.button1.Location = new System.Drawing.Point(72, 40);

                this.button1.Name = "button1";

                this.button1.Size = new System.Drawing.Size(160, 160);

                this.button1.TabIndex = 0;

                this.button1.Text = "Ayyüzlüm.mp3";

                this.button1.Click += new System.EventHandler(this.button1_Click);

                // 

                // mainMenu1

                // 

                this.mainMenu1.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] {

                                                                                          this.menuItem1,

                                                                                          this.menuItem6,

                                                                                          this.menuItem7});

                // 

                // menuItem1

                // 

                this.menuItem1.Index = 0;

                this.menuItem1.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] {

                                                                                          this.menuItem2,

                                                                                          this.menuItem3,

                                                                                          this.menuItem4,

                                                                                          this.menuItem5});

                this.menuItem1.Text = "Muzikler";

                // 

                // menuItem2

                // 

                this.menuItem2.Index = 0;

                this.menuItem2.Text = "ayyüzlüm";

                // 

                // menuItem3

                // 

                this.menuItem3.Index = 1;

                this.menuItem3.Text = "bla bla";

                // 

                // menuItem4

                // 

                this.menuItem4.Index = 2;

                this.menuItem4.Text = "ceza";

                // 

                // menuItem5

                // 

                this.menuItem5.Index = 3;

                this.menuItem5.Text = "manga";

                // 

                // menuItem6

                // 

                this.menuItem6.Index = 1;

                this.menuItem6.Text = "ÇIK";

                // 

                // menuItem7

                // 

                this.menuItem7.Index = 2;

                this.menuItem7.Text = "Yardım";

                // 

                // Form1

                // 

                this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);

                this.ClientSize = new System.Drawing.Size(292, 266);

                this.Controls.Add(this.button1);

                this.Menu = this.mainMenu1;

                this.Name = "Form1";

                this.Text = "MP3";

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

                this.ResumeLayout(false);

     

            }

            #endregion

     

            /// <summary>

            /// The main entry point for the application.

            /// </summary>

            [STAThread]

            static void Main() 

            {

                Application.Run(new Form1());

            }

     

            private void button1_Click(object sender, System.EventArgs e)

            {

                 

                System.Diagnostics.Process Proc = new System.Diagnostics.Process();

                Proc.StartInfo.FileName = "wmplayer.exe";

                Proc.StartInfo.CreateNoWindow = true;

                Proc.StartInfo.Arguments = "/hide d:\\muzik\\01-ayyüzlüm.mp3"; //siz bunu kendi diskinizdeki mp3 yerel adresiyle değiştireceksiniz.

               

                Proc.Start();

     

            }

     

            private void Form1_Load(object sender, System.EventArgs e)

            {

             

            }

        }

    }

  2. KısayolKısayol reportŞikayet pmÖzel Mesaj
    ArmadA
    ArmadA's avatar
    Kayıt Tarihi: 08/Ekim/2005
    Erkek

    höö mp3 çalma derken winamp gibimi ? 


    Living Death
  3. KısayolKısayol reportŞikayet pmÖzel Mesaj
    SinusX
    SinusX's avatar
    Kayıt Tarihi: 14/Aralık/2010
    Erkek

    http://naudio.codeplex.com/

    şuda çok kullanışlı bi kütüphanedir tavsiye ederim lazım olan olursa.


    Si vis pacem para bellum.
  4. KısayolKısayol reportŞikayet pmÖzel Mesaj
    Elif - Efe
    rakkoc
    rakkoc's avatar
    Kayıt Tarihi: 19/Aralık/2003
    Homo
    S1b3r_HasTa bunu yazdı

            private void button1_Click(object sender, System.EventArgs e)

            {

                System.Diagnostics.Process Proc = new System.Diagnostics.Process();

                Proc.StartInfo.FileName = "wmplayer.exe";

                Proc.StartInfo.CreateNoWindow = true;

                Proc.StartInfo.Arguments = "/hide d:\\muzik\\01-ayyüzlüm.mp3"; //siz bunu kendi diskinizdeki mp3 yerel adresiyle değiştireceksiniz.

                Proc.Start();

            }

     

    windows media playeri aciyorsunda hocam geri kapatiyormusun ?


    Bu aralar fazla yogunum. Unuttugum seyler oluyorsa affola. DM vs atın.
  5. KısayolKısayol reportŞikayet pmÖzel Mesaj
    SharpShooter
    SharpShooter's avatar
    Banlanmış Üye
    Kayıt Tarihi: 10/Temmuz/2008
    Erkek

    bu kod gezse geze

    hackturkiye, zonkhack.com da falan gezer hocam.

    burası için bi anlamı yok :)


    - xx yerde hata var. - ya aslında kod şöyle sanıyor olabilir bla bla bla - olm kendine gel kodlar düşünmez - ...
  6. KısayolKısayol reportŞikayet pmÖzel Mesaj
    Elif - Efe
    rakkoc
    rakkoc's avatar
    Kayıt Tarihi: 19/Aralık/2003
    Homo
    SharpShooter bunu yazdı

    bu kod gezse geze

    hackturkiye, zonkhack.com da falan gezer hocam.

    burası için bi anlamı yok :)

    ios konusunda tartissakta dostum bu konuda katiliyorum :)


    Bu aralar fazla yogunum. Unuttugum seyler oluyorsa affola. DM vs atın.
  7. KısayolKısayol reportŞikayet pmÖzel Mesaj
    S1b3r_HasTa
    S1b3r_HasTa's avatar
    Kayıt Tarihi: 16/Temmuz/2005
    Erkek

    http://www.hazirkod.com/8e340d5d-d4c8-49ad-87af-a2a9c03a9ad3/4/csharp/mp3-calmak.html

    hazirkod yöneticisinin kendi adıyla yayımladığı kodlarım 15bin kere bakıldığına göre [2004 yılında] birşeyler ifade eder belki sana, seni ilgilendirmiyorsada konuma maydonoz olmazsın olur biter

  8. KısayolKısayol reportŞikayet pmÖzel Mesaj
    nessaj
    nessaj's avatar
    Kayıt Tarihi: 03/Mayıs/2010
    Erkek
    S1b3r_HasTa bunu yazdı

    http://www.hazirkod.com/8e340d5d-d4c8-49ad-87af-a2a9c03a9ad3/4/csharp/mp3-calmak.html

    hazirkod yöneticisinin kendi adıyla yayımladığı kodlarım 15bin kere bakıldığına göre [2004 yılında] birşeyler ifade eder belki sana, seni ilgilendirmiyorsada konuma maydonoz olmazsın olur biter

    ne ifade edicek, bi process başlatmayı göstermek için 200 satır kod paylaşmışsın, millet kırmadan sana birşey anlatmak istiyor anlamak istemiyorsun.

    kod gereksiz ve saçma. boru gibi wmp componenti varken tutupta ayrı process olarak wmp yi başlatıp salmışın çayıra. acemi adamın bile işine yaramıyacak kod. 

    son postum.

  9. KısayolKısayol reportŞikayet pmÖzel Mesaj
    S1b3r_HasTa
    S1b3r_HasTa's avatar
    Kayıt Tarihi: 16/Temmuz/2005
    Erkek

    aramızda 5 sene var üyelik bakımından ve benim o kodu yazdığım yıllarda öyle birşey yoktu assembly bilmeden kodlamayı anlamaya çalışan zihnin ürünüsün aynen devam koç

  10. KısayolKısayol reportŞikayet pmÖzel Mesaj
    S1b3r_HasTa
    S1b3r_HasTa's avatar
    Kayıt Tarihi: 16/Temmuz/2005
    Erkek

    bi process başlatmayı göstermek için 200 satır kod paylaşmışsın demene rağmen kendi kişiliğinle profilinde ne de güzel çelişmişsin ne yazıyor acaba profilinde

    Programlama işindeki ilerlemeyi satır sayısı ile ölçmek, uçak imalatı işindeki ilerlemeyi ağırlıkla ölçmek gibi olur

    bill gates

    komiksin akşam akşam güldürdün beni...

    S1b3r_HasTa tarafından 27/Eyl/12 23:23 tarihinde düzenlenmiştir
  11. KısayolKısayol reportŞikayet pmÖzel Mesaj
    Elif - Efe
    rakkoc
    rakkoc's avatar
    Kayıt Tarihi: 19/Aralık/2003
    Homo
    S1b3r_HasTa bunu yazdı

    aramızda 5 sene var üyelik bakımından ve benim o kodu yazdığım yıllarda öyle birşey yoktu assembly bilmeden kodlamayı anlamaya çalışan zihnin ürünüsün aynen devam koç

    ilk once soyledign sey cok buyuk terbiyesizlik. BURASI INCI DEGIL. sen y neslisin ben x nesliyim muhabbetinin yapilacagi yer degil burasi.

    Eger oyle ise bak bende de senden eskiyim!

    Progres Start orneyi vermek istiyorsan google'dan haziri

     

    Code Project bunu yazdı

     

            /// <summary>
            /// Executes a shell command synchronously.
            /// </summary>
            /// <param name="command">string command</param>
            /// <returns>string, as output of the command.</returns>
            public void ExecuteCommandSync(object command)
            {
                try
                {
                    // create the ProcessStartInfo using "cmd" as the program to be run,
                    // and "/c " as the parameters.
                    // Incidentally, /c tells cmd that we want it to execute the command that follows,
                    // and then exit.
                    System.Diagnostics.ProcessStartInfo procStartInfo =
                        new System.Diagnostics.ProcessStartInfo("cmd", "/c " + command);
    
                    // The following commands are needed to redirect the standard output.
                    // This means that it will be redirected to the Process.StandardOutput StreamReader.
                    procStartInfo.RedirectStandardOutput = true;
                    procStartInfo.UseShellExecute = false;
                    // Do not create the black window.
                    procStartInfo.CreateNoWindow = true;
                    // Now we create a process, assign its ProcessStartInfo and start it
                    System.Diagnostics.Process proc = new System.Diagnostics.Process();
                    proc.StartInfo = procStartInfo;
                    proc.Start();
                    // Get the output into a string
                    string result = proc.StandardOutput.ReadToEnd();
                    // Display the command output.
                    Console.WriteLine(result);
                }
                catch (Exception objException)
                {
                    // Log the exception
                }
            }
    
            /// <summary>
            /// Execute the command Asynchronously.
            /// </summary>
            /// <param name="command">string command.</param>
            public void ExecuteCommandAsync(string command)
            {
                try
                {
                    //Asynchronously start the Thread to process the Execute command request.
                    Thread objThread = new Thread(new ParameterizedThreadStart(ExecuteCommandSync));
                    //Make the thread as background thread.
                    objThread.IsBackground = true;
                    //Set the Priority of the thread.
                    objThread.Priority = ThreadPriority.AboveNormal;
                    //Start the thread.
                    objThread.Start(command);
                }
                catch (ThreadStartException objException)
                {
                    // Log the exception
                }
                catch (ThreadAbortException objException)
                {
                    // Log the exception
                }
                catch (Exception objException)
                {
                    // Log the exception
                }
            }

    O zamanlar bu api yok diyorsun. yazdigin kodun ne ise yaradigini bilmiyorsun heralde. API eklenmis fakat kullanilmamis.

     

    S1b3r_HasTa bunu yazdı

     

    using WMPLauncher;

    using WMPLib;

     

     


    Bu aralar fazla yogunum. Unuttugum seyler oluyorsa affola. DM vs atın.
Toplam Hit: 3403 Toplam Mesaj: 12