[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [ns] Problem with list in parameter
As John Mehringer <[email protected]> suggested before:
Any arguments passed that have spaces maybe mistaken as 2 arguments. It
is best to put {} around your tcl arguments so that tcl will know for
sure to treat a string with a space as one argument.
Try using this:
$ns at 0.0 "$n0 hello {$list}"
and see if it fixes the problem.
- John Mehringer
Hope this solves your problem
Nick
[email protected] wrote:
> Hello. I have a problem. When I use a function in a tcl simulation with a list
> in parameter, it doesn't work. For example if I use it like this :
> $ns at 0.0 "$n0 hello $list"
> It works when the list has only one argument.
>
> But It works when there is just
> $n0 hello $list
> (even if the list has many arguments).
>
> Can somebody tell me how doing that.
>
> ALCATEL SPACE INDUSTRIES
> DTS/DAT/E -- Stagiaire
> Tel : 33 (0) 5 34 35 37 52 / Fax : 33 (0) 5 34 35 61 69
> Porte : F-2070 / E-Mail : [email protected]
John Mehringer <[email protected]>