Help

The Community will be temporarily unavailable starting on Friday February 28. Weā€™ll be back as soon as we can! To learn more, check out our Announcements blog post.

Converting ASCII values

Topic Labels: Formulas
Solved
Jump to Solution
3398 1
cancel
Showing results for 
Search instead for 
Did you mean: 
Josh_Jennings
4 - Data Explorer
4 - Data Explorer

Is it possible to convert integer values into ASCII characters in Formula columns? Pseudo code example: convertToChar(71) returns the char ā€˜Gā€™.

1 Solution

Accepted Solutions
JonathanBowen
13 - Mars
13 - Mars

Hi @Josh_Jennings - donā€™t think you can do this with a formula, but you can achieve it with a script block:

Screenshot 2020-03-10 at 20.10.01

// @ts-nocheck
let table = base.getTable("Table");

let tableQuery = await table.selectRecordsAsync();

for (let record of tableQuery.records) {
    let result = record.getCellValueAsString("Name");
    let updateValue = String.fromCharCode(result);
    await table.updateRecordAsync(record, {
        "Result": updateValue
    })
}

JB

See Solution in Thread

1 Reply 1
JonathanBowen
13 - Mars
13 - Mars

Hi @Josh_Jennings - donā€™t think you can do this with a formula, but you can achieve it with a script block:

Screenshot 2020-03-10 at 20.10.01

// @ts-nocheck
let table = base.getTable("Table");

let tableQuery = await table.selectRecordsAsync();

for (let record of tableQuery.records) {
    let result = record.getCellValueAsString("Name");
    let updateValue = String.fromCharCode(result);
    await table.updateRecordAsync(record, {
        "Result": updateValue
    })
}

JB