
正文
vb.netwmi方式的简单介绍
提示:扫一扫查出行【扫一扫了解最新限行尾号】
复制提示
求大神指点vb.net 怎么以指定方式打开图片呢?
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
'建立新的系统进程
Dim process As New System.Diagnostics.Process()
If RadioButton1.Checked Then
'设置文件名,此处为图片的真实路径+文件名
process.StartInfo.FileName = "c:\a.bmp"
'设置进程运行参数
process.StartInfo.Arguments = "rundll32.exe shimgvw.dll"
Else
process.StartInfo.FileName = "mspaint.exe"
process.StartInfo.Arguments = "c:\a.bmp"
End If
'此项为是否使用Shell执行程序,因系统默认为true,此项也可不设,但若设置必须为true
'process.StartInfo.UseShellExecute = True
'此处可以更改进程所打开窗体的显示样式,可以不设
'process.StartInfo.WindowStyle = System.Diagnostics.ProcessWindowStyle.Hidden
process.Start()
process.Close()
End Sub
vb.netwmi方式的介绍就聊到这里吧,感谢你花时间阅读本站内容,更多关于、vb.netwmi方式的信息别忘了在本站进行查找喔。






