# Cross out the price

**URL:** https://community.glideapps.com/t/cross-out-the-price/38151
**Category:** Ask for Help
**Created:** [February 5, 2022, 11:32am UTC](https://community.glideapps.com/t/cross-out-the-price/38151 "2022-02-05T11:32:56Z")
**Posts on this page:** 1
**Showing post:** 6

<div class="post-metadata">

### Author: ![Jeff\_Hager](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/jeff_hager/32/43_2.png) [@Jeff\_Hager](https://community.glideapps.com/u/Jeff_Hager)
#### Post date: [February 5, 2022, 4:45pm UTC](https://community.glideapps.com/t/cross-out-the-price/38151/6 "2022-02-05T16:45:05Z")

</div>

You could either use a template column to replace all of the numbers with the strikethrough version of the same number, or you could create a javascript code column that converts it like this:

![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/0/a/0adc4df91f0884c2c5fc19cc008f6477dd229c98.png)

 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/c/c/ccfa7ff7e2fa07c65c72d84ca95cc6d1a7aa29d1.png)

```auto
return strikeThrough(p1.toString());

function strikeThrough(text) {
  return text
    .split('')
    .map(char => char + '\u0336')
    .join('')
}

```

The problem is that it loses the formatting from the number column, so you could use something like this version, which adds the ‘Rp’ and adds the thousands separator. It doesn’t add the decimal if it’s zero, but probably could be done if needed.

```auto
return strikeThrough("Rp " + p1.toLocaleString());

function strikeThrough(text) {
  return text
    .split('')
    .map(char => char + '\u0336')
    .join('')
}

```

![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/c/5/c54ee9a36d04859af43c860b2dce70e79b83d341.png)

The end result looks like this in a card:

 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/e/2/e27c8001a1e5126760d8aead30a4fcdc6dedfdd0.png)

---

_[View the full topic](https://community.glideapps.com/t/cross-out-the-price/38151)._
