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.

HFSLIP script problem with KB898461

Featured Replies

Hi everyone,

I did a new installation, but Windows update installer package KB898461 (which is present in the HF folder) and several other updates were missing. So I checked the HFSLIP script and found this on line 482:

IF EXIST HF\*898461*.exe (
FOR /F %%I IN ('DIR/B/OD HF\*898461*.exe') DO SET PKGINST=%%I
ECHO !PKGINST!&MD TEMP&START/WAIT HF\!PKGINST! /Q /X:TEMP
...
)

I tested this section with this test:

@ECHO ON
IF EXIST HF\*898461*.exe (
FOR /F %%I IN ('DIR/B/OD HF\*898461*.exe') DO SET PKGINST=%%I
ECHO PKGINST=%PKGINST%
)
PAUSE

When I run it, I get this output:

C:\hfslipWxp>SET PKGINST=WindowsXP-KB898461-x86-DEU.exe
PKGINST=

The variable PKGINST is set, but in the next line, the contents of the variable is gone.

Has anyone a solution for this?

I'm using Windows XP Pro SP3 German and checked my source with Mimo's File-Checker.


I haven't tried your test myself, but just off the top shouldn't this:

ECHO PKGINST=%PKGINST%

be this?:

ECHO PKGINST=!PKGINST!

Also, you'll need to add this at the beginning of your test:

SETLOCAL EnableDelayedExpansion

So, like this overall:

@ECHO ON
SETLOCAL EnableDelayedExpansion
IF EXIST HF\*898461*.exe (
FOR /F %%I IN ('DIR/B/OD HF\*898461*.exe') DO SET PKGINST=%%I
ECHO PKGINST=!PKGINST!
)
PAUSE

  • Author

Thanks jinjou,

that worked. I always thought that referencing the contents of a DOS variable was done this way:

ECHO PKGINST=%PKGINST%

What is the difference with exclamation marks or when do I have to use that?

Greets

Kukris

I always thought that referencing the contents of a DOS variable was done this way:

ECHO PKGINST=%PKGINST%

You're correct, this is the right way to do it, except when you set the value of a variable in a block (typically, an IF or a FOR statement).

What is the difference with exclamation marks or when do I have to use that?

You can find an explanation for all this in the online help text of the commands.

Try these commands at a prompt:

SET /?

HELP

HELP SET

HELP SETLOCAL

Also, try these to find additional important information:

HELP CALL
HELP FOR
HELP IF

However, this matter doesn't apply to your original issue, and is not related to this forum. If you have any further questions along this line, you should post to here.

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.