Question: I want to bind an action to two commands that will be done one after the other. I've tried the following syntax:

```
$g marker bind $point <Button-1> [list $table HighLightCell 1 [expr [lindex $value 1] + 3] \; __highlight_selected $table $sparam $eyes sparam_eyes $graph]

```

I've also tried few other variations, but none of them worked.

`$g` is a blt graph, and it handles binds like normal binds in Tk. What happens is that Tcl thinks that all the parameters are parameters for `$table HighLightCell` and doesn't interprate the `;` as the end of one command and start of a new command.

I can't use `{...}` syntax because I need to put variables in the commands, which I'm not able to do using `{...}`. How can I put 2 commands that will be done when the event happens, without creating a new proc that will call those commands?

Answer: 
Even if I agree that the `proc` way is the better one, you can try the following two ways.

The first one, is to use double quotes for grouping, `"..."`, which are similar to braces, but allows variable expansion and command substitution. Your code will be something like:

```
$g marker bind $point <Button-1> "$table HighLightCell 1 [expr [lindex $value 1] + 3] ; __highlight_selected $table $sparam $eyes sparam_eyes $graph"

```

(Note that the semicolon is not escaped.)

The second one, is to use `eval`, and to defer the execution of the two commands to it. You can try this:

```
$g marker bind $point <Button-1> [list eval $table HighLightCell 1 [expr [lindex $value 1] + 3] \; __highlight_selected $table $sparam $eyes sparam_eyes $graph]

```

`eval` just calls the interpreter on a command formed by its arguments. If among them there is a semicolon, the commands will be two. The semicolon must be escaped, this time, because it must be interpreted by the `eval` and not before.

I tried both the methods with the following simple codes, and they both works:

```
set x 1
set y 2
pack [button .b1 -text Test1]
pack [button .b2 -text Test2]
bind .b1 <Button-1> "puts $x; puts $y"
bind .b2 <Button-2> [list eval puts $x \; puts $y]

```

Clicking on either the buttons gives the same result, which is the expected

```
1
2

```

One more thing, it's better to put the arguments of the `expr` command inside braces, so in your code you should replace

```
expr [lindex $value 1] + 3

```

with

```
expr {[lindex $value 1] + 3}

```

You don't have to worry about the substitution of the `$value` variable and about the execution of the `lindex` command: `expr` does that for you, but it also optimize the execution. You can find some more information in the wiki (<http://wiki.tcl.tk/583>), or in the `expr` manual page (<http://www.tcl.tk/man/tcl8.5/TclCmd/expr.htm>).
Use `+` at the beginning of the next script to bind, like this:

```
bind . <KeyPress-a> "puts one"
bind . <KeyPress-a> "+ puts two"

```