|
#1
|
||||
|
||||
|
Conditional Script for Multiple Variables in File Properties
I see posting on how to define a single variable with one screen of radio buttons...but how do I define multiple variables in the script conditions text box in the File Properties?
I have created 2 Radio button screens, one to ask which language (French or English) which I am capturing in %Language% and the other screen to capture which version of PowerPoint they are running (2000 or 2002,2003,2007) [My PowerPoint Addin is in 2 versions, one for Powerpoint 2000 and one for Powerpoint 2002,2003 or 2007, hence I am leaving it up to user to select which PowerPoint version they have] on LanguageScreen1 I defined this on Next action after placing 2 radio buttons... Code:
if String.ToNumber(SessionVar.Expand("%Language%")) ==
CTRL_RADIO_BUTTON_01 then
English = true;
French = false;
else
English = false;
French = true;
end
Code:
French Code:
English I cant figure out how to have the second condition added in the textbox... is it with an AND and parenthesis? I need some examples please.. I tried the following and it doesnt work Code:
French AND 2000 Code:
(French) AND (2000 = TRUE) Code:
(French) AND (2002 = TRUE) OR (2003 = TRUE) OR (2007 = TRUE) Some examples would be nice...please.. If someone has an alternative way of doing it, I am open to it. thank you in advance... |
|
#2
|
||||
|
||||
|
I'm confused by your question; you talk about screen conditions (there are none in suf7/8) and file properties....
Can you post a sample project wtih what you've tried so we can look at what you're doing? |
|
#3
|
||||
|
||||
|
Here is a sample project
in screens, you have 2 radio button screens that capture data... then in conditions you will see that I tried various ways to selectivly install. the possible install options are 1. English + Powerpoint 2000 2. English + Powerpoint 2002 or 2003 or 2007 3. French + Powerpoint 2000 4. French + Powerpoint 2002 or 2003 or 2007 and then some common files, which is easy. hope you follow now... thanks |
|
#4
|
||||
|
||||
|
So you are dealing with conditional FILES not screens...
I looked at one file; it's wrong: Code:
French AND OfficeChoice = 2000 Code:
French AND OfficeChoice == 2000 |
|
#5
|
||||
|
||||
|
then how to do multiple conditions in that one text box? Should it be like:
Code:
French AND OfficeChoice == 2002 AND OfficeChoice == 2003 AND OfficeChoice == 2007 |
|
#6
|
||||
|
||||
|
Quote:
it's one or the other. Perhaps you mean: Code:
French AND (OfficeChoice == 2002 or OfficeChoice == 2003 or OfficeChoice == 2007) |
|
#7
|
||||
|
||||
|
Yes, I really did mean an OR not an AND.
Let me try this and will let you know... |
|
#8
|
||||
|
||||
|
Just remember to use the parenthesis ....
|
|
#9
|
||||
|
||||
|
Still getting error...
|
|
#10
|
||||
|
||||
|
it's and not AND
it's or not OR be sure to use == not = |
|
#11
|
||||
|
||||
|
SOLVED: Conditional Script for Multiple Variables in File Properties
That worked! it was the Upper Case "AND" that was causing the problem.
From my experience, Boolean operators are defined in UPPER CASE...why this different? thank you for your help... worked out perfectly! |
|
#12
|
||||
|
||||
|
Because that's how the designers of the LUA scripting language decided it should be.
|
![]() |
| Tags |
| script, variables |
«
Previous Thread
|
Next Thread
»
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Hundreds of Variables - How can I edit the .APM File? | CJM | AutoPlay Media Studio 4.0 | 9 | 04-30-2003 01:44 PM |
| Utility to create AMS Script to set Variables to "" | Worm | AutoPlay Media Studio 4.0 | 10 | 02-05-2003 01:54 PM |
| INFO: Tips for Debugging Action Lists in AutoPlay Media Studio 4.0 | Support | AutoPlay Media Studio 4.0 Examples | 0 | 10-03-2002 09:38 AM |
| Can search allow manual browse even if file is found? | RichardShaw | Setup Factory 5.0 | 2 | 08-28-2000 07:08 PM |
| Install only into one of several directories with specific existing file? | RichardShaw | Setup Factory 5.0 | 0 | 08-17-2000 03:29 PM |
All times are GMT -6. The time now is 10:37 AM.










Linear Mode

