Select to view content in your preferred language

Changing button label on click

2394
2
Jump to solution
05-01-2012 07:56 AM
SamirGambhir
Frequent Contributor
This should be fairly simple but I cannot figure it out. I am using dojo button in a form. I would like the button to change its label from ABC to DEF when clicked. I am trying to use dijit.byId(button id).label="DEF" but it does not seem to work. Any suggestions?
Thanks in advance
Samir
0 Kudos
1 Solution

Accepted Solutions
derekswingley1
Deactivated User
Use the button dijit's set method:
dijit.byId("T1465").set("label", "New Label");

View solution in original post

0 Kudos
2 Replies
derekswingley1
Deactivated User
Use the button dijit's set method:
dijit.byId("T1465").set("label", "New Label");
0 Kudos
SamirGambhir
Frequent Contributor
Thanks Derek,
Samir
0 Kudos