Ana içeriğe atla

C#(Sharp) ile PC'den Ses Çıkartma Kodları

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.Runtime.InteropServices;

namespace Pcden_ses_cikarma
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        [DllImport("Kernel32.dll", EntryPoint = "Beep")]
        public static extern long MyBeep(Int32 frekans, Int32 sure);
        private void button1_Click(object sender, EventArgs e)
        {
            MyBeep(1000, 1500);
        }
    }
}










-----Kolay Gelsin-----

Yorumlar

Bu blogdaki popüler yayınlar

Microsoft Excel Temel Eğitim Ders Notları - Excel Programına Giriş

Microsoft Excel Temel Eğitim Ders Notları - Özel Veri Giriş Yöntemleri

C#(Sharp) ile PC Oturumunu Kapatma

using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Windows.Forms; using System.Runtime.InteropServices; namespace Oturum_kapat {     public partial class Form1 : Form     {         public Form1()         {             InitializeComponent();         }         [DllImport("user32.dll")]         public static extern int ExitWindowsEx(int uFlags, int dwReserved);         void OturumKapat()         {             ExitWindowsEx(0, 0);         }    ...