on 09-06-2006 6:19 AM
Hi,
I have a input field on a view , i want to make it <b>readonly</b> during run time depending on some value.
plz help. reward point is sure.
Hi
Create a boolean attribute and bind it to the input field's readOnly property .And you can change the property at run time.
Kind Regards
Mukesh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks to all of you . my problem has been solved.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Manoj
You can also make the input field readOnly dynamically during run time. For this you need to write a simple code in wdDoModifyView of your view controller. Code is as follows
IWDInputField inputField = (IWDInputField)view.getElement("<id of inputfield>");
if(<reqd condition>)
{
inputField.setEnabled(false);
}
else
{
inputField.setEnabled(false);
}
Try this, if things donot get much complicated on doing this. I hope it helps u and makes thing simple.
Regards
Kapil
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Create an attribute with type boolean.
Then bind this to readonly property of the inputfield.
then check the condition and set that attribute to true.
wdContext.CurrentContextElement.setReadOnlyAtt(true);
Regards,
Vijayakhanna Raman
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
86 | |
10 | |
10 | |
9 | |
6 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.