I have a quite simple problem: use manipulate to create and edit a table with identifiers in first column and abbreviations in second column. I am new with manipulate and dynamic modules. I have written a code that works.
ClearAll["Global`*"]
low = CharacterRange["a", "g"];
nRows = 4;
abb[r_] := Table[
ToExpression["R" <> ToString[r] <> low[[i]]] -> low[[i]], {i, 1,
Length[low]}];
row[r_] := {ToExpression["Row" <> ToString[r]],
ToExpression["R" <> ToString[r] <> "a"], abb[r]}
rec[{id_, abb_, ru_}] := {id,
ToExpression[StringTake[ToString[abb], -1]]}
file = Table[row[r], {r, 1, nRows}];
control[{id_, abbr_, rules_}] := {
InputField[Dynamic[id]],
PopupMenu[Dynamic[abbr], rules]
}
Manipulate[
MatrixForm[Map[rec, file]],
Grid[Map[control, file]],
ContinuousAction -> None,
ControlPlacement -> Left
]
But I find it much too complicated. Would there be a more natural way to proceed? Is it possible to avoid using the update button. Thanks