Jump to content

Recommended Posts

Posted

Hello

I would like to launch an installation of a file .inf with a script autoit as on the image with right clic

post-15470-1175532415_thumb.jpg

it's possible ?

"Donne un poisson à un homme, il mangera un jour. Apprends lui à pècher, il mangera toujours."-Proverbe chinois-
Posted

Hi, i think you need this one:

$InfFile = "Test.inf"

Run(@SystemDir & "\rundll32.exe setupapi,InstallHinfSection DefaultInstall 132 " & $InfFile)

 

  Reveal hidden contents

 

 

AutoIt is simple, subtle, elegant. © AutoIt Team

Posted

  MsCreatoR said:

Hi, i think you need this one:

$InfFile = "Test.inf"

Run(@SystemDir & "\rundll32.exe setupapi,InstallHinfSection DefaultInstall 132 " & $InfFile)
I try but that did not function :shocked:
"Donne un poisson à un homme, il mangera un jour. Apprends lui à pècher, il mangera toujours."-Proverbe chinois-
Posted (edited)

CODE
  from Microsoft said:

Microsoft source page link

Create an Autorun.inf File

Autorun.inf is a text file that is located in the root folder of your application CD-ROM. It provides to the computer the name and the location of the startup program for your application that is installed when the CD-ROM is inserted. The Autorun.inf file can also contain optional information including the following:

⢠The name of a file that contains an icon that represents your application's CD-ROM drive. This icon appears in Windows Explorer instead of the standard drive icon.

⢠Additional commands for the shortcut menu that appears when the user right-clicks the CD-ROM icon. You can also specify the default command that runs when the user double-clicks the icon.

Autorun.inf files are similar to .ini files. They include one or more sections. Each section has a name that is enclosed in square brackets. Each section contains a series of commands that the Windows Shell runs when the user inserts the disc. The following two sections are currently defined for Autorun.inf files:

⢠The [autorun] section contains the default Autorun commands. All Autorun.inf files must have an [autorun] section.

⢠An optional [autorun.alpha] section can be included for Microsoft Windows NT 4.0 systems running on RISC-based computers. When a CD-ROM is inserted in a CD-ROM drive on a RISC-based system, the Windows Shell runs the commands in this section instead of those in the [autorun] section.

Each section contains a series of commands that determine how the Autorun operation occurs. The following five commands are available:

⢠defaulticon: Specifies the default icon for the application.

⢠icon: Specifies the path and the file name of an application-specific icon for the CD-ROM drive.

⢠open: Specifies the path and the file name of the startup application.

⢠shell: Defines the default command in the shortcut menu of the CD-ROM.

⢠shell\verb: Adds commands to the shortcut menu of the CD-ROM.

The following is an example of a simple Autorun.inf file. It specifies Filename.exe as the startup application. The second icon represents the CD-ROM drive instead of the standard drive icon.

IASScript 1.84 may help you customize easier. You can create your file by using certain commands and verbs.

:shocked:

Edit:

Good example and further information at the Autorun Wiki here.

Edited by MHz

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...