Skip to content
View in the app

A better way to browse. Learn more.

MSFN

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Simple "Inf" File

Featured Replies

I have created a simple (.inf) file named cleanup.inf.

Here it is:

[Version]

Signature=$CHICAGO$

[DefaultInstall]

DelFiles=cleanup

[cleanup]

MSN Explorer.lnk

;end of file

Anyway, my goal is to delete the MSN Explorer icon in the following directory:

C:\Documents and Settings\All Users\Desktop\MSN Explorer.lnk

How do I tell the inf the file is in a specific directory. I'm confused on writing my first inf. I'm used to batch files. All the examples I see on the internet just name the file that you want to delete WITHOUT any path to the filename. My concern is that I have multiple MSN Explorer.lnk files. I only want to delete the one in the path that i've given above. Could someone help me out with this example? I thank you in advance if you could help because i'm not understanding.

Thanks, Niatross

Edited by Nihilator


The path to the files to delete for a DelFiles section must be specified via the DestinationDirs section.

Add this to your inf :

[DestinationDirs]
cleanup=16409

16409 is the "magic number" to specify the "%AllUsersProfile%\Desktop" folder.

(taken from here)

Also, you should change the signature to "$Windows NT$", 'coz your INF may not run on 9x.

See also this site and clik "Infs" in the top menu ;)

  • Author

Thanks Delprat. I see how it works. Thanks very much :)

I have one more question. If I want to delete the cleanup.inf after it runs my clean up commands, how would I do it?

It seems like I would have to do it on next reboot since this inf is in memory running.

Thanks, Niatross

It seems like I would have to do it on next reboot since this inf is in memory running.
I don't think so.

Try to add another 'DelFiles' section for your inf:

[DefaultInstall]
DelFiles=cleanup,cleandown

[cleandown]
myself.inf

[DestinationDirs]
cleanup=16409
cleandown=YourInfFolder

May I ask why do you want to use .inf instead of batch for this?

  • Author

I'm choosing inf over batch because it's cleaner. A batch shows a cmd window when it runs, then diappears quicky, which is ugly. I'm going to be running this inf from my [GUIRUNONCE].

Edited by Nihilator

I'm choosing inf over batch because it's cleaner. A batch shows a cmd window when it runs, then diappears quicky, which is ugly. I'm going to be running this inf from my [GUIRUNONCE].

An INF shows a "copying files" window if there is at least one CopyFiles= section or one AddReg= section in the Install section being processed (and that window "stucks" during all the install process, but the progressbar shows only the copying process).

I don't use [GUIRUNONCE], but if it allows command line parameters you can use StartX.exe to hide the cmd window before it's creation :

X:\Path_to\StartX.exe /WAIT /B Z:\Path_to\YourBatch.cmd

(search on the forum for a DL link to StartX)

That's less "ugly" that using CMDOW @ /HID (I guess that's you're using, am I right ?)

Create an account or sign in to comment

Recently Browsing 0

  • No registered users viewing this page.

Account

Navigation

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.