expr store

derf07's icon
Hello.I'm looking to use this function with the expr object.
 The Max console displayed: the store function requires 3 arguments.
My question is: what are these 3 arguments?
Thanks for your help.
TFL's icon

According to the last tab of the expr help file, first argument is the table name to store the data to (followed by [-1], don't ask me why), second argument is the index and last argument is the value.

For example if you send 100 to a [expr store(tab[-1], $i1, $i2 / 2], it will store the value 50 at the index 100 of the table named tab.

Roman Thilenius's icon

these three should be name of the table, index, and value to store.

but i dont know the exact synthax, just tried it and do not get it to work. i think one of these "arguments" noted by the error message in the console is the $s# itself.

TFL's icon

For the sake of a more explicit example

Max Patch
Copy patch and select New From Clipboard in Max.