TheDeveloperBlog.com

Home | Contact Us

C-Sharp | Java | Python | Swift | GO | WPF | Ruby | Scala | F# | JavaScript | SQL | PHP | Angular | HTML

JavaScript String toUpperCase() Method

JavaScript string toUpperCase() Method with example, by string literal, by string object (using new keyword), javascript string methods, charAt(index) method, concat(str) method, indexOf(str) method, lastIndexOf(str) method, lowerCase() method, upperCase() method, slice(beginIndex, endIndex) method, trim() method, toLowerCase(), slice(), concat(), charCodeAt() method etc.

<< Back to JAVASCRIPT

JavaScript String toUpperCase() Method

The JavaScript string toUpperCase() method is used to convert the string into uppercase letter. This method doesn't make any change in the original string.

Syntax

The toUpperCase() method is represented by the following syntax:

string.toUpperCase()

Return

String in uppercase letter.

JavaScript String toUpperCase() Method Example

Let's see some simple examples of toUpperCase() method.

Example 1

Here, we will print the string in uppercase letter.

<script>
var str = "TheDeveloperBlog";
document.writeln(str.toUpperCase());
</script>
Test it Now

Output:

JAVATPOINT

Example 2

This is one more example to print the string in uppercase letter.

<script>
var str = "TheDeveloperBlog TUTORIALS";
document.writeln(str.toUpperCase());
</script>
Test it Now

Output:

JAVATPOINT TUTORIALS

Next TopicJavaScript String




Related Links:


Related Links

Adjectives Ado Ai Android Angular Antonyms Apache Articles Asp Autocad Automata Aws Azure Basic Binary Bitcoin Blockchain C Cassandra Change Coa Computer Control Cpp Create Creating C-Sharp Cyber Daa Data Dbms Deletion Devops Difference Discrete Es6 Ethical Examples Features Firebase Flutter Fs Git Go Hbase History Hive Hiveql How Html Idioms Insertion Installing Ios Java Joomla Js Kafka Kali Laravel Logical Machine Matlab Matrix Mongodb Mysql One Opencv Oracle Ordering Os Pandas Php Pig Pl Postgresql Powershell Prepositions Program Python React Ruby Scala Selecting Selenium Sentence Seo Sharepoint Software Spellings Spotting Spring Sql Sqlite Sqoop Svn Swift Synonyms Talend Testng Types Uml Unity Vbnet Verbal Webdriver What Wpf