I am trying to update a existing component in this below code snippet, where "index" is index of existing component.
TextField l = new TextField();
l.setText(txt);
t.addComponent(index, l);
From the above, new component is being added at the end instead of updating to that indexed component. How we can achieve updating the existing component ?