MSFN Forum: Check OS and install hotfixes - MSFN Forum

Jump to content



Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Check OS and install hotfixes Rate Topic: -----

#1 User is offline   rokey 

  • Group: Members
  • Posts: 7
  • Joined: 01-June 04

Posted 07 October 2004 - 08:26 AM

looking for a good solution... or is this a bug?

i wont use wihu to install hotfixes. i have made an entry in wihu that check the os and then it checks if the hotfix is installed or not.
but i have problem diselect the hotfix when it is not the right os :( have someone made the same with a working solution? or made i a mistake in the install.ini?

here is the install.ini

Quote

[Test for Hotfixes]help=help\hotfix.rtf
description.0=Hotfixes WinXP
command.0="command"
test.0.0 = HKLM:SOFTWARE\Microsoft\Windows NT\CurrentVersion\CurrentVersion?=5.0
test.eval.0 = 0
Disabled.0 = if.false, inherit
Selected.0 = if.true, inherit

description.0.0=Hotfix 1
command.0.0="command"
test.0.0.0 = HKLM:SOFTWARE\Microsoft\Updates\Windows XP\SP1\Q282784\
test.eval.0.0 = 0
Disabled.0.0 = if.true
Selected.0.0 = if.false

description.0.1=Hotfix 2
command.0.1 ="command"
test.0.1.0 = HKLM:SOFTWARE\Microsoft\Updates\Windows XP\SP2\KB282010\
test.eval.0.1 = 0
Disabled.0.1    = if.true
Selected.0.1 = if.false

description.0.2=Hotfix 2
command.0.2 ="command"
test.0.2.0 = HKLM:SOFTWARE\Microsoft\Updates\Windows XP\SP2\KB814841\
test.eval.0.2 = 0
Disabled.0.2    = if.true
Selected.0.2 = if.false


here is a picture how it looks:

Attached File(s)




#2 User is offline   BenjaminKalytta 

  • Developer
  • PipPipPipPip
  • Group: Members
  • Posts: 609
  • Joined: 08-June 04

Posted 07 October 2004 - 11:45 AM

Hi rokey,
you are testing for "CurrentVersion=5.0" here which only returns TRUE if, and only if you are using Windows 2000. So only if you are using Windows items get selected and enabled.
So once again, if "Hotfixes WinXP" is unchecked then, NONE of it's subitems will be installed although it's subitems may be checked. So dont worry about this. But may be I should modify WIHU for consistency reasons. selected.x = v, inherit should also set it's subitems to "v"

Benjamin

#3 User is offline   BenjaminKalytta 

  • Developer
  • PipPipPipPip
  • Group: Members
  • Posts: 609
  • Joined: 08-June 04

Posted 08 October 2004 - 01:13 PM

I fixed this. Should work now as intended.

Benjamin

#4 User is offline   rokey 

  • Group: Members
  • Posts: 7
  • Joined: 01-June 04

Posted 08 October 2004 - 02:25 PM

wow thanks man! the subitems will now be unchecked!! THX

...but i believe there is now an other small bug. if the inherit switch is there, the key check for the subitems will not work an the section will not be unchecked, if the os is ok :( without the inherit switch it works. but without the inherit switch the os check wil not really work, because the subitems will not be disabled :(

#5 User is offline   BenjaminKalytta 

  • Developer
  • PipPipPipPip
  • Group: Members
  • Posts: 609
  • Joined: 08-June 04

Posted 08 October 2004 - 05:46 PM

Yes, sorry you could be right :} I'll fix this tommorow (GMT).

Benjamin

#6 User is offline   BenjaminKalytta 

  • Developer
  • PipPipPipPip
  • Group: Members
  • Posts: 609
  • Joined: 08-June 04

Posted 10 October 2004 - 05:33 AM

I had to revert changes I made yesterday because this causes some more parsing problems.

Take following example:

[My Section]
test.0.0 = wihu.exe
test.eval.0 = 0
command.0 = ...
description.0 = ...
selected.0 = if.true, inherit
disabled.0 = if.false, inherit

test.0.0.0 = wihu.abc.exe
test.eval.0.0 = 0
selected.0.0 = if.true
command.0.0 = ...
description.0.0 = ...


If we presume that test.eval.0 returns TRUE (wihu.exe) exists, we will select this item. So further we presume test.eval.0.0 will return FALSE. Here is the point. Which state should be set to selected.0.0? If we inherit it from selected.0 (checked) we will check this item although test.eval.0.0 returned FALSE. Othwerwise if test.eval.0.0 would have returned TRUE this item will selected too. This doesn't make any sense.

Benjamin

#7 User is offline   XPect 

  • Junior
  • Pip
  • Group: Members
  • Posts: 80
  • Joined: 18-June 04

Posted 10 October 2004 - 10:24 AM

I agree, if a sub item doesn't respect the same selection rules than the orignal item, inherit sould not be used, it's just logic.

I got the same problem to differentiate a program installation than the icon removal and the registering. At the end it's more logic to just add a different test per sub item, even is the test is the same for several sub items...

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users



All trademarks mentioned on this page are the property of their respective owners
Copyright © 2001 - 2011 msfn.org
Privacy Policy