通过USB自动启动应用程序(通过自动运行?) [英] Automatically launch app on USB (through autorun?)

查看:268
本文介绍了通过USB自动启动应用程序(通过自动运行?)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以从USB闪存驱动器中自动启动应用程序(绕过Windows提示询问用户他想做什么)?在Windows XP或Vista上。

Is it possible to automatically launch an application from a USB flash drive (bypassing windows prompt asking user what he wants to do)? on windows XP or vista.

我调查了 autorun.inf和打开条目,似乎仅适用于Windows XP SP2 +和Vista的CD驱动器。

I looked into "autorun.inf" and "open" entry seems to work only for CD drives for Windows XP SP2+ and Vista. Is it possible to launch program automatically on all windows versions?

我不在乎用户是否在Windows设置中禁用了自动运行。

I don't care if autorun is disabled by user in Windows settings.

推荐答案

首先,出于安全原因,有些人选择禁用自动运行。但是Windows Vista或更高版本的Windows计算机已启用它。编辑:显然,该功能已从Windows 7开始删除。

First of all, some people choose to disable autorun for security reasons; but Windows computers up to Vista have it enabled. Apparently the functionality was removed from Windows 7 onwards.

在USB闪存驱动器的根目录中放置一个名为autorun.inf的文件。这是我的东西:

Put a file named autorun.inf in the root of your USB flash drive. This is what's in mine:

[Autorun]
Open=PStart.exe
Action=Start portable apps
Icon=diskicon.ico

功能:插入此磁盘时,启动 PStart.exe

What it does: when you insert this disk, starts PStart.exe

在较旧的计算机上,在 Open = 将自动启动。

On older computers, the program specified in Open= will launch automatically.

在大多数现代计算机(Windows XP SP2 +,Vista)上,将显示您想做什么对话框(出于安全性考虑)原因),但 autorun.inf 中的内容将显示为选定的默认值,并以 Icon = 作为图标, Action = 作为说明。如果要启动它,只需单击对话框中的确定按钮。

On most modern computers (Windows XP SP2+, Vista), dialog "what do you want to do" will be displayed (for security reasons), but what you have in autorun.inf will display as the selected default, with Icon= as icon and Action= as description. If you want to launch it, just click the "OK" button in the dialog.

因此,尽管我不知道有什么方法可以启动应用程序(例如 PStart ),则可以使用此配置插入闪存磁盘,然后单击确定启动应用程序。

So, although I'm not aware of any way to start the application (e.g. PStart) immediately, it is possible to insert flash disk with this configuration and start application by clicking OK.

已在不同计算机上运行测试,但没有运行SP,也已在Windows XP sp 1,sp2,sp3和各种Vista上运行(不确定哪种类型,但应该在所有从Vista Home Basic到Vista Enterprise Super-Mega-Premium-Extended Edition)和 Windows 7。在Windows 2000上也可以使用(尽管在默认配置中未在Win2000上针对可移动驱动器自动运行)。

Tested on different computers, running Windows XP without a SP, also on Windows XP sp 1, sp2, sp3, and on various Vistas (not sure which types, but should work all the way from Vista Home Basic to Vista Enterprise Super-Mega-Premium-Extended Edition) and "Windows 7". Also works on Windows 2000 (although autorun on Win2000 for removable drives is not enabled in default configuration).

请注意,某些应用程序可能还会触发未知/就像您手动打开它们一样。

Note that some applications, in addition, may trigger the "unknown/unsigned exacutable" security dialog, as if you opened them manually.

编辑:有关更多详细信息,请参见:

在Windows XP中自动播放:自动检测系统上的新设备并对其进行反应

For more details, see also:
Autoplay in Windows XP: Automatically Detect and React to New Devices on a System

这篇关于通过USB自动启动应用程序(通过自动运行?)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆