vb.net编写1ms截图程序
Imports System.Drawing
Imports System.Drawing.Imaging
Imports System.Runtime.InteropServices
Public Class Form1
Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
End Sub
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
Dim bmpScreenshot As Bitmap = Me.CaptureScreen() '获取屏幕截图
bmpScreenshot.Save("d:\test\screenshot" & Now & ".png", ImageFormat.Png) '保存为png格式
End Sub
Function CaptureScreen() As Bitmap '截取屏幕函数
Dim bmpScreenshot As New Bitmap(Screen.PrimaryScreen.Bounds.Width, Screen.PrimaryScreen.Bounds
创作工场
免责声明:
以上内容除特别注明外均来源于网友提问,创作工场回答,未经许可,严谨转载。
点击这里>>使用🔥专业版,更聪明、更完整、更原创!