'charCodeAt()' Example : charCodeAt « Javascript Methods « JavaScript Reference

'charCodeAt()' Example

    
<html>
<body>
<button onclick="var myS = new String('Sample String'); 
                 alert(myS.charCodeAt(3));">get char at an index</button>
</body>
</html>

    
      
      








Related examples in the same category

1.'charCodeAt()' Syntax, Parameters and Note
2.'charCodeAt()' is applied to