This project has moved and is read-only. For the latest updates, please go here.

[Solved] Operators: "AND" & "OR"

Topics: Publishing Issue
Dec 21, 2013 at 11:19 AM
Hello Team,

Need explanation on how to use "AND" & "OR" operators in update installed or update installable window.

For ex: I am installing shockwave with below rule, then how should I write this in WPP

Installable rule:

Install only if
For 32bit - check for File Version "And" File Exist "And" Processor Arch
Or
For 64bit - check for File Version "And" File Exist "And" Processor Arch

Processor Arch 32
And
File Version 32
And
File Exist 32

Or

Processor Arch 64
And
File Version 64
And
File Exist 64

Hope the query is understandable.
Dec 21, 2013 at 2:39 PM
This is an example "Is Installable" rule (Change the version number to feet to the release you deploy) :

IsInstallableRule

This mean :

If
{ Processor is x86
And
The file C:\Program Files (x86)\Adobe\Shockwave\ShockWave.exe EXIST
And
The version of the file C:\Program Files (x86)\Adobe\Shockwave\ShockWave.exe is LESS than 11.4.3.486
}
OR
{ Processor is x64
And
The file C:\Program Files\Adobe\Shockwave\ShockWave.exe EXIST
And
The version of the file C:\Program Files (x86)\Adobe\Shockwave\ShockWave.exe is LESSthan 11.4.3.486
}
End If


You can, also, copy/paste this text into a new text file :
<lar:Or>
<lar:And>
<bar:Processor Architecture="0"/><bar:FileExists Path="C:\Program Files (x86)\Adobe\Shockwave\ShockWave.exe"/><bar:FileVersion Path="C:\Program Files (x86)\Adobe\Shockwave\ShockWave.exe" Comparison="LessThan" Version="11.4.3.486"/></lar:And>
<lar:And>
<bar:Processor Architecture="9"/><bar:FileExists Path="C:\Program Files\Adobe\ShockWave\ShockWave.exe"/><bar:FileVersion Path="C:\Program Files\Adobe\Shockwave\ShockWave.exe" Comparison="LessThan" Version="11.4.3.486"/></lar:And>
</lar:Or>
rename the file into : ShockWave.rules, and import it into WPP.
Marked as answer by DCourtel on 1/17/2014 at 7:47 AM
Dec 23, 2013 at 2:48 PM
Thanks for the screenshot, but how did you manage to take the complete screenshot.
As I am not able to move the package level rules to down and couldn't get the complete screen even maximizing the window.

If possible can we have a option to open rules in another window (full screen)
Dec 23, 2013 at 3:43 PM
It is a clever mix of screenshots and MS Paint ;-)
Jan 14, 2014 at 2:12 PM
only way to control this operators is use "Load Rules" and all operators job do in Notepad....

If you try to do this in GUI u will fail...

maybe its possible to fix this?
Jan 14, 2014 at 8:04 PM
creaton wrote:
If you try to do this in GUI u will fail...
As you can see in the screenshot, it's possible.
maybe its possible to fix this?
What do you want to be fix ?
Jan 16, 2014 at 5:20 AM
Adding Rules in current GUI is possible, but a better GUI can be made for ease of adding rules for starters.
Jan 16, 2014 at 8:04 AM
Hi rahulwithu, can you explain what is a 'better GUI' for you ? Can you describe this GUI ? How you imagine/see it ?
Jan 17, 2014 at 8:05 AM
Edited Jan 17, 2014 at 8:15 AM
Hey!
By the way want to say thank to developers. excellent product.

About GUI i get the point how to use it, so must say sorry about my previus post. GUI works but you should spent little bit more time to understand how exactly. :P

The problem were with choose right area where you want to add your condition.




P.S "EDIT" are u sure is right name for this button? maybe something like "switch mode" "switch OR/AND"
P.P.S is it possible to add option to choose size of update level area? better to see all of condition.
Image
Jan 26, 2014 at 8:10 PM
In the V2, IsInstallable Rules and IsInstalled Rules will be in a separate Tab. Help section will be hide et displayed when clicking on a '?' icone.
Users will toggle between Update Level and Package Level by clicking on a button.
Mar 6, 2014 at 5:10 PM
I think its wrong: if Architecture is 0 (that means x86 - 32 bits) --> the file is in Program Files
              and if Architecture is 9 (that means x64) - 64 bits) --> the file is in Program Files (x86)
It doesnt matter, because I try to write that rule for developing Firefox and doesnt work. I mean, in one client that doen't have that file, it should appear that update as "Not Apllicable", but it appeard for downloading. What am I doing wrong?
Mar 29, 2014 at 7:18 PM
Hello,

I try to check if a software is already installed today (pdf creator).
I follow your indication with the XML Rules files.

Effectivly like say albricia I must switch the architecture (0 and 9).

But I have also another problem (I use latest version) and they not working.
I try to delete C:\program Files (x86) and use the default folder system instead and this working.

I give the Complete XML File :
<lar:Or>
<lar:And>
<bar:Processor Architecture="9"/>
<bar:FileExists Path="\PDFCreator\PDFCreator.exe" Csidl="42"/>
</lar:And>

<lar:And>
<bar:Processor Architecture="0"/>
<bar:FileExists Path="\PDFCreator\PDFCreator.exe" Csidl="38"/>
</lar:And>
</lar:Or>
Thank's to the team for this wonderful application.
Apr 29, 2014 at 10:19 AM
Edited Apr 29, 2014 at 10:21 AM
I found this thread because I'm having a general Problem with setting the Operator 'OR' at the beginning of a rule. When I have started the Assistant. on the page where to set the 'Is installed' Rule, it always begins with 'AND' operator and I can't delete it and replace with 'Or'. How can I force the WPP-Update-Assistant to assume <Start OR> or with an empty Rule?
Apr 29, 2014 at 10:25 AM
Ok, just found the solution by myself :D I have to click on Edit and then it asks me to change from 'AND' to 'OR'
Solved