Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\Simu]
"URL Protocol"="D:\\Ezviz Studio\\EzvizProtect.exe"
@="SimuProtocol"
[HKEY_CLASSES_ROOT\Simu\DefaultIcon]
@="D:\\Ezviz Studio\\EzvizProtect.exe,1"
[HKEY_CLASSES_ROOT\Simu\shell]
[HKEY_CLASSES_ROOT\Simu\shell\open]
[HKEY_CLASSES_ROOT\Simu\shell\open\command]
[HKEY_CLASSES_ROOT\Simu]
"URL Protocol"="D:\\Ezviz Studio\\EzvizProtect.exe"
@="SimuProtocol"
[HKEY_CLASSES_ROOT\Simu\DefaultIcon]
@="D:\\Ezviz Studio\\EzvizProtect.exe,1"
[HKEY_CLASSES_ROOT\Simu\shell]
[HKEY_CLASSES_ROOT\Simu\shell\open]
[HKEY_CLASSES_ROOT\Simu\shell\open\command]
@="\"D:\\Ezviz Studio\\EzvizProtect.exe\" \"%1\""
把上面这段保存为.reg文件,导入注册表
测试
<html>
<head>
</head>
<body>
<a href="Simu://canshu">点击打开目标程序</a>
</body>
</html>
本文介绍了一个具体的案例,展示了如何通过编辑Windows注册表来定义一个新的URL协议Simu,并将其与特定的应用程序EzvizProtect.exe关联起来。通过创建并导入一个.reg文件到Windows注册表中,用户可以实现从网页链接直接启动应用程序并传递参数的功能。
1108

被折叠的 条评论
为什么被折叠?



