REPT function – create a Cell chart

Is it possible to use a cell to display a bar indicator like a bar chart, based on another cell’s value?

By Neale Blackwood

The REPT function allows you to repeat a character a defined number of times. If cell A1 contained 65, the following formula will display 65 vertical lines in the cell. =REPT(“

“,A1)

The

symbol can be found above the / key on most keyboards. If cell A1 contained text, the formula would display the #VALUE error. You can use this technique to build simple indicators without having to create a chart.

This technique allows you to easily place the indicators on the sheet. You could also apply a conditional format to the cell to vary its colour depending on the length of the cell contents.