I'm trying to do the following:
I have a table:
w = Table[ToExpression[ToString[h] <> ToString[i]], {i, 1, Length[c]}]
This table is suposed to generate variables, like the following list:
{h1, h2, h3, h4, h5, h6, h7, h8, h9, h10, h11}
I'm trying to create a table of vertical sliders with this by adding this to the code:
w = Table[VerticalSlider[Dynamic[ToExpression[ToString[h] <> ToString[i]]]], {i, 1, Length[c]}]
It create a it gives me an error:
Set::write: "Tag ToExpression in \!\(ToExpression[\"hi\"]\) is Protected.
I'm aware that this may not be the best way todo this but it's all I can imagine, I guess the other feasible way would be with loops, I don't know. Can you help me?


cis not defined anywhere. – gpap Mar 7 at 15:59Length[c]with whatever lengthchas in your original code or givec(not the case here, but it could have been thatcwas too long and that caused your problem - a working snippet would help exclude such cases). – gpap Mar 7 at 21:19