社区
C#
帖子详情
C#有没有类似 VisualBasic.Interaction.Shell 的类?
微wx笑
Java领域优质创作者
博客专家认证
2011-11-15 11:24:32
我知道C#中有个:System.Diagnostics.Process.Start
不知道还有没有其它的
...全文
332
2
打赏
收藏
C#有没有类似 VisualBasic.Interaction.Shell 的类?
我知道C#中有个:System.Diagnostics.Process.Start 不知道还有没有其它的
复制链接
扫一扫
分享
转发到动态
举报
AI
作业
写回复
配置赞助广告
用AI写文章
2 条
回复
切换为时间正序
请发表友善的回复…
发表回复
打赏红包
微wx笑
2013-06-29
打赏
举报
回复
虽然不是我想要的答案,但分得送出去。
sdl2005lyx
2011-11-15
打赏
举报
回复
Windows的API:
[DllImport("shell32.dll")]
public extern static int ShellExecute(IntPtr hwnd,
string lpOperation,
string lpFile,
string lpParameters,
string lpDirectory,
int nShowCmd
);
软件开机自启不修改注册表
using Wsh
Shell
= Microsoft.
Visual
Basic
.
Interaction
.CreateObject("WScript.
Shell
"); // 创建快捷方式对象 Wsh
Shell
shell
= new Wsh
Shell
(); IWshShortcut shortcut = (IWshShortcut)
shell
.CreateShortcut...
vs2019提示Microsoft.
Visual
Basic
中“不存在
Interaction
”
在VS2019中,Microsoft.
Visual
Basic
命名空间已经不再默认包含
Interaction
类
,需要手动添加对Microsoft.
Visual
Basic
.dll的引用才能使用
Interaction
类
。注意:在使用
Interaction
类
时,需要确保你的程序是以Windows ...
C#
引用Microsoft.
Visual
Basic
将目录或文件删除到回收站。
usingSystem.Runtime.InteropServices; privateconstintFO_DELETE=0x3; privateconstushortFOF_NOCONFIRMATION=0x10; privateconstushortFOF_ALLOWUNDO=0x40;...
shell
32.dll")] privatestat...
C#
调用外部程序的三种实现方式
在
C#
开发中,经常需要调用外部...
C#
提供了多种方式来调用外部程序,本文将介绍其中的三种主要方法:System.Diagnostics.Process
类
、System.
Shell
类
(通过 Microsoft.
Visual
Basic
.
Interaction
)以及使用
C#
的 Syste...
c#
使用wscript.shel发送按键
需要引用Microsoft.
Visual
Basic
再加入命名空间 using Microsoft.
Visual
Basic
; //为了wscript.
shell
,必须引用 dynamic
shell
Object =
Interaction
.CreateObject("WScript.
Shell
", ""); //使用wscript.
shell
,用于...
C#
111,097
社区成员
642,554
社区内容
发帖
与我相关
我的任务
C#
.NET技术 C#
复制链接
扫一扫
分享
社区描述
.NET技术 C#
社区管理员
加入社区
获取链接或二维码
近7日
近30日
至今
加载中
查看更多榜单
社区公告
让您成为最强悍的C#开发者
试试用AI创作助手写篇文章吧
+ 用AI写文章