MSFN Forum: Toggle between 2 versions .. - MSFN Forum

Jump to content



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

Toggle between 2 versions .. Rate Topic: -----

#1 User is offline   midiboy 

  • Senior Member
  • PipPipPipPip
  • Group: Members
  • Posts: 586
  • Joined: 04-July 04

Posted 02 February 2005 - 07:24 AM

Hi Benjamin,

I hope I am not disturbing your studying for exams too much ... :D

Just came across a situation where I would want an option in Wihu to toggle between two programs to be installed. The reason is this:

I want to give the user an option to choose between two versions of a program to install. Version 1 and 2 for instance.

He can choose to install version 1 or versions 2 or no version at all but he should not be allowed to check both versions since that would lead to conflicts during installation.

I am not sure if there is a command for this yet in Wihu. Or is there ? :unsure:

It should be that if the user selects version 1, he should not be able to check version 2 anymore and vice versa.

Anyway, would be nice to have something like that ...

Thanks ,
Bye,
Alex


#2 User is offline   XPect 

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

Posted 02 February 2005 - 10:43 AM

This one is quite easy, it's show in the install.ini that come with wihu

Quote

description.0.1.2=Group test
command.0.1.2=cmd.exe /c @echo command.0.1.2
group.0.1.2=1

description.0.1.2.0=Option 1
command.0.1.2.0=cmd.exe /c @echo Option 1
description.0.1.2.1=Option 2
command.0.1.2.1=cmd.exe /c @echo Option 2
description.0.1.2.2=Option 3
command.0.1.2.2=cmd.exe /c @echo Option 3
selected.0.1.2.1 = 1
group.0.1.2.0=1
The command to use is goup.x = 1
This signify that the lower levels are options and that you can only select one of them.

Hope this help.

#3 User is offline   midiboy 

  • Senior Member
  • PipPipPipPip
  • Group: Members
  • Posts: 586
  • Joined: 04-July 04

Posted 02 February 2005 - 03:30 PM

Hi XPect,

thanks for your help. However, I donīt get it ... :P

I tried this:

[Diverses]

Description.0=Programm 1
command.0=CMD /C "%WIHU%\..\Test\silent_install.cmd"
workdir.0="%WIHU%\..\Test"
selected.0=0


group.1=1

Description.1.0=Option 1
command.1.0=CMD /C "%WIHU%\..\Option1\silent_install.cmd"
workdir.1.0="%WIHU%\..\Option1"
selected.1.0=0

Description.1.1=Option 2
group.1=1
command1.1=CMD /C "%WIHU%\..\Option2\silent_install.cmd"
workdir.1.1="%WIHU%\..\Option2"
selected.1.1=1


Description.2=Programm 3
command.2=CMD /C "%WIHU%\..\Test2\silent_install.cmd"
workdir.2="%WIHU%\..\Test2"
selected.2=1


The result is that only program 1 is displayed.
:wacko:

I am tired ... :rolleyes:

Bye,
Alex

#4 User is offline   BenjaminKalytta 

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

Posted 02 February 2005 - 04:37 PM

Your INI section isn't correct.
Example:

[Diverses]

group.1 = 1

command.1 = cmd.exe
description.1 = Option 1

command.1.0 = cmd.exe
description.1.0 = Option 1.0

command.1.1 = cmd.exe
description.1.1 = Option 1.1


This will produce following output:

Diverses
[ ] Option 1
    ( ) Option 1.0
    ( ) Option 1.1


Quote

I hope I am not disturbing your studying for exams too much ...


Im really very stressed at the moment until 13th. I failed at least 2 examinations right now. That's very annoying. But after 13th I've enough time to do necessary left out work on WIHU ;)


Benjamin Kalytta

#5 User is offline   midiboy 

  • Senior Member
  • PipPipPipPip
  • Group: Members
  • Posts: 586
  • Joined: 04-July 04

Posted 02 February 2005 - 04:57 PM

Hi Benjamin,

thanks, yes, it works now. Seemingly one has to add a command at the top group position (command.1 in your example), otherwise it does not work. I added a dummy command now and it works.

Quote

Im really very stressed at the moment until 13th. I failed at least 2 examinations right now. That's very annoying. But after 13th I've enough time to do necessary left out work on WIHU


Good luck then ! :thumbup

Bye
Alex

#6 User is offline   BenjaminKalytta 

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

Posted 03 February 2005 - 05:01 AM

Btw. adding group = 1 on top tree like following is also possible:

[section]
group = 1

command.0 = cmd.exe
description.0 = Option 1

command.1 = cmd.exe
description.1 = Option 2


Benjamin Kalytta

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