Javascript change to uppercase

Change text to UpperCase using Javascript
Suppose, I want to convert lowercase chars to uppercase as the user types using Javascript. In this article,I will explain How to Change text to UpperCase using Javascript.We are using following JavaScript code to Change text to UpperCase using Javascript.

The keyup() method is used to Bind an event handler to the "keyup" JavaScript event, or trigger that event on an element and The toUpperCase() method converts a string to uppercase letters.
You can use javascript toUpperCase() method to Change text to UpperCase using Javascript.
In the following code we have called the  keyup event in the JavaScript to Change lowercase chars to uppercase. This function would be called when any user enters char on the textbox .
The javascript code below shows how to Change text to UpperCase using Javascript

Example: Change text to UpperCase using Javascript
<!DOCTYPE html>
<title>Change lowercase chars to uppercase with Javascript</title>
Enter your name: <input type="text" id="name" onKeyUp="LowerToupperCase()" />
<script type="text/javascript">
function LowerToupperCase()
var name=document.getElementById("name");