![](templates/Classic/images/spacer.gif) |
shalimar GURU
![](images/avatars/114658559147aeed8fee539.gif)
Joined: 04 Aug 2002 Posts: 4717 Location: Pensacola, FL, USA
|
Posted: Sun Apr 19, 2009 8:27 pm
[3.06] Misclaimed, mismatched braces |
Code: |
<alias name="updateGame" id="121">
<value>$this=%params
$that=@{this.$this}
#IF ($that>0) {%expandlist($this)=$that}</value>
</alias> |
For some reason it says there is a mismatched brace in my #IF statement... can anyone tell me why? |
|
_________________ Discord: Shalimarwildcat |
|
|
![](templates/Classic/images/spacer.gif) |
shalimar GURU
![](images/avatars/114658559147aeed8fee539.gif)
Joined: 04 Aug 2002 Posts: 4717 Location: Pensacola, FL, USA
|
Posted: Sun Apr 19, 2009 8:39 pm |
i changed the #IF to this to get things working... but i still dont see what was wrong with my original code...
#IF ($that>0) {#VAR %expandlist($this) {$that}} |
|
_________________ Discord: Shalimarwildcat |
|
|
![](templates/Classic/images/spacer.gif) |
Fang Xianfu GURU
![](images/avatars/1763170544a2093e7e85da.gif)
Joined: 26 Jan 2004 Posts: 5155 Location: United Kingdom
|
Posted: Sun Apr 19, 2009 9:40 pm |
Because the = assignment operator requires the variable name to be a simple name - it can't evaluate functions. That's what the #var command is for, and using it as you are in your second post is the correct way to do this.
|
|
|
![](templates/Classic/images/spacer.gif) |
Arde Enchanter
Joined: 09 Sep 2007 Posts: 605
|
Posted: Sun Apr 19, 2009 9:43 pm |
Hmm... Start line with a command?
P.S. Can you tell me what you expect your #VAR %expandlist($this) {$that} will do if $this will have more than 1 element? Just interesting... |
|
_________________ My personal bug|wish list:
-Wrong Priority when copy-paste setting
-1 prompt trigger for Mapper, Session and General Options, not 3 different!
-#SECTION can terminate threads
-Buttons can't start threads |
|
|
![](templates/Classic/images/spacer.gif) |
Caled Sorcerer
Joined: 21 Oct 2000 Posts: 821 Location: Australia
|
Posted: Mon Apr 20, 2009 12:53 am |
Yeah, I'm curious about what that could do as well.
|
|
_________________ Athlon 64 3200+
Win XP Pro x64 |
|
|
![](templates/Classic/images/spacer.gif) |
shalimar GURU
![](images/avatars/114658559147aeed8fee539.gif)
Joined: 04 Aug 2002 Posts: 4717 Location: Pensacola, FL, USA
|
Posted: Mon Apr 20, 2009 12:06 pm |
Oh, I was using massive indirection in my solving a sudoku puzzle package.
It was a great mental excersize!
the way im using it, $this is always a single alphanumeric... but i suspect that it would put my value into the default value field |
|
_________________ Discord: Shalimarwildcat |
|
|
![](templates/Classic/images/spacer.gif) |
|
|