hi!
I want to validate if WebEditor is null or not having any text please help me.
Hi,
If you are interested in changes, then it is better to process ClientSideEvents.ValueChange/TextChanged/InvalidValue. If you need a current value in editor, then you may use getValue(), getText() and other more specific member functions for a specific editor. Please consult CSOM docs for editors. Below an example:
<igtxt:WebNumericEdit ID="WebNumericEdit1" runat="server"></igtxt:WebNumericEdit><igtxt:WebMaskEdit ID="WebMaskEdit1" runat="server" InputMask="(###)###-####" DataMode="RawText"></igtxt:WebMaskEdit>
<script type="text/javascript">function checkVal(){ var str = ''; var num = igedit_getById('WebNumericEdit1'); if(num) str += "Numeric value='" + num.getValue() + "'\n"; var mask = igedit_getById('WebMaskEdit1'); if(mask) str += "Text in maskedit='" + mask.getValue() + "'"; window.alert(str);}</script>
Regards,ViktorInfragistics web team