当前位置:网站首页>C# 调用系统声音 嘀~
C# 调用系统声音 嘀~
2022-07-02 06:32:00 【清山博客】
public class BeepUp
{
/// <param name="iFrequency">声音频率(从37Hz到32767Hz)。在windows95中忽略</param>
/// <param name="iDuration">声音的持续时间,以毫秒为单位。</param>
[DllImport("Kernel32.dll")] //引入命名空间 using System.Runtime.InteropServices;
public static extern bool Beep(int frequency, int duration);
}调用方法:
BeepUp.Beep(3200, 100);声音频率 和 持续时间 可以自行调整。
边栏推荐
- [blackmail virus data recovery] suffix Rook3 blackmail virus
- Introduction to anti interception technology of wechat domain name
- Jumping | Blue Bridge Cup
- What are the platforms for selling green label domain names? What is the green label domain name like?
- How to apply for a secondary domain name?
- File upload and download performance test based on the locust framework
- 2022 Heilongjiang latest construction eight members (materialman) simulated examination questions and answers
- Finishing the interview essentials of secsha system!!!
- Analysis of the use of comparable, comparator and clonable interfaces
- Installing Oracle database 19C for Linux
猜你喜欢

kubernetes部署loki日志系统

OpenShift构建镜像

Comparable,Comparator,Clonable 接口使用剖析

群辉 NAS 配置 iSCSI 存储

使用wireshark抓取Tcp三次握手
![[untitled]](/img/6c/df2ebb3e39d1e47b8dd74cfdddbb06.gif)
[untitled]

c语言将字符串中的空格替换成%20

Gateway 简单使用
![[blackmail virus data recovery] suffix Hydra blackmail virus](/img/27/f44334cf98229d0f8b33c70a878ca8.jpg)
[blackmail virus data recovery] suffix Hydra blackmail virus

Classes and objects (instantiation of classes and classes, this, static keyword, encapsulation)
随机推荐
Programmer training, crazy job hunting, overtime ridiculed by colleagues deserve it
Sqli labs level 12
What are the platforms for selling green label domain names? What is the green label domain name like?
The best blog to explain the basics of compilation (share)
Mutex
判断是否是数独
First week of JS study
Jz-061-serialized binary tree
Sentinel 简单使用
Linux二进制安装Oracle Database 19c
Nacos download, start and configure MySQL database
History of Web Technology
Minecraft群组服开服
Honeypot attack and defense drill landing application scheme
C language replaces spaces in strings with%20
Gateway 简单使用
Implementation of bidirectional linked list (simple difference, connection and implementation between bidirectional linked list and unidirectional linked list)
Application of kotlin - higher order function
Zipkin is easy to use
Network security - summary and thinking of easy-to-use fuzzy tester