Oct 01 2023 01:53 AM
How can we reduce the font size of Decimal Value in excel? (Just like its shown in image)
Oct 01 2023 03:06 AM
It is impossible to do that with numbers.
It would be possible if you converted the number to a text value, but that would cause problems with calculations:
Oct 01 2023 06:44 AM
Many things are possible That is not to say they are worth doing! For example, you could commit separate columns for dollars and cents and format each as you like.
summing the column would require a bit of effort though.
Sum2Partsλ(amount)
= LET(
values, TAKE(twoCol, , 1) + ROUND(TAKE(twoCol, , -1) / 100, 2),
result, SUM(values),
HSTACK(INT(result), ROUND(100 * (result - INT(result)), 0))
)
[ Note: the integer cents are formatted using the number format "\.00" ]
Oct 01 2023 07:54 AM
Alternatively, you could do it with VBA without having to convert it to text.
Attached is an example file.
Oct 01 2023 08:27 AM
Niko, please note that the values in your sample workbook are text values. They are left-aligned while horizontal alignment is set to General, and the formula =SUM(A1:A3) returns 0.
If I convert the values to numbers, your macro has no effect.
Oct 01 2023 09:28 AM
Oct 01 2023 11:43 AM
It is not possible to format part of a number, date or TRUE/FALSE value differently from the rest, only of text values. And if a cell contains a formula, it is not possible at all, regardless of the data type of the return value.