#1
|
|||
|
|||
dynamic asseymblies
is if then else statements the only expression that one can use in
the expression value?? Has anyone played with this?? |
#2
|
|||
|
|||
Hallo,
The if-then-else statement is the only structural statement that can be used for expressions. However using mathematical expressions and other relations allows a wide range of possibilties to express desired behavior. What exactly are you looking for? Mario |
#3
|
||||
|
||||
using conditional operators (<, >, <=, >=, etc) in combination with if-then-else can give you several posibilities, but also logical relations can provide a lot of possibilities.
here's an example: vnum1=0 (a variable number that will be annimated from 0-20) vlog1= vnum1 >= 5 vlog2= vnum1 >= 10 vlog3= vnum1 >= 15 each one of the above logical relations (vlogx) is checking if vnum1 is greater than or equal to it's corresponding number. If it is not, vlogx=0 or false. If it is, vlogx=1 or true) (now put thes logical relations in if statement for an angle relation (ang1)) if vlog1 then 45 else if vlog2 then 90 else if vlog3 then 135 else 180 then you simply annimate vnum1 and watch the angle change as vnum1 changes. |
#4
|
|||
|
|||
Hi chris,
why would you use the variables vlogx instead of using the logical expression itself ? Mario |
#5
|
||||
|
||||
This was just an example, you could use logical expressions here also.
chris
__________________
Chris P. Whitman Senior Technical Sales Specialist PTC/CoCreate Last edited by chris; 05-21-2003 at 02:57 PM. |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
|
|