Form1.cs
(开头部分) 6KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading;
using System.Windows.Forms;
namespace USBAutoPlayer
{
using System;
using System.IO;
using System.Management;
using System.Runtime.InteropServices;
using System.Windows.Forms;
public partial class Form1 : Form
{
const int WM_DEVICECHANGE = 0x219; //u盘如后的硬件设备改变消息
//const int DBT_DEVICEARRIVAL = 0x8000; //u盘可用
const int DBT_DEVICEARRIVAL = 0x00000007; //u盘可用
const int DBT_DEVICEREMOVECOMPLETE = 0x8004; //设备删除
//string SN = "4C530102100829110303";
string SN = "C03FD5F76CBAE510E310E822";
string currentSN;
string Path1 = Environment.CurrentDirectory+@"\Data\111.mp4";
[DllImport("user32", EntryPoint = "ShowCursor")]
public extern static bool ShowCursor(bool show);
[DllImport("user32.dll")]
static extern void BlockInput(bool Block);
public Form1()
{
InitializeComponent();
}
private void PlayVideo() //播放视频
{
ShowCursor(false);
BlockInput(true);
axWindowsMediaPlayer1.URL = Path1;
axWindowsMediaPlayer1.settings.setMode("loop", true);
axWindowsMediaPlayer1.uiMode = "none";
axWindowsMediaPlayer1.enableContextMenu = false;
axWindowsMediaPlayer1.Ctlenabled = false;
axWindowsMediaPlayer1.Ctlcontrols.play();
}
private void T1(object info) //读取设备
{
ManagementClass cimobject = new ManagementClass("Win32_DiskDrive");
ManagementObjectCollection moc = cimobject.GetInstances(); //获取设备集合
后面还有 131 行代码,解锁后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。