---
description: How to convert field input to UPPERCASE while entering characters
---

# Convert Values to UPPERCASE (Option B)

![a Case ID converting to UPPERCASE as entered](https://3087753818-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LzNSSXajDFpzOv2IhIv%2F-MX9Fti0sJAPmpTmPEPB%2F-MXY317IcmxE2Q93HuPT%2Fimage.png?alt=media\&token=9c14cac3-ab58-460e-adb2-a3a7ae7db148)

### The JS

The function

```
/*****************************************/
/*** Convert Field/Inputs to UpperCase ***/
/*****************************************/
$(document).on("knack-page-render.any", function (event, page) {
```

We create a handler that uses the keyup function. We can create one that applies to an entire field type such as the Name field (i.e. Customer Name and Reviewer Name)

```
//All Name Fields
  $('.kn-input-name input').keyup(function(){
      this.value = this.value.toUpperCase();
  });
```

or we can target a specific field by using the Knack Field ID

```
//Specific Field   
   $('input#field_165').keyup(function(){
      this.value = this.value.toUpperCase();
  });
```

and dont forget to close the function.

```
})
```

Example of full code block

```
/*comment*/
$(document).on('knack-page-render.any', function(event, page) {
  $('input#field_1047').keyup(function(){
    this.value = this.value.toUpperCase();
  });
})
```

### The CSS

None needed 😎

### How to Implement

Adjust field input type or Field ID and you are set 👍

```
'.kn-input-name input'
```

```
'input#field_165'
```

