Answer the question
In order to leave comments, you need to log in
Custom Excel format to correctly display long numbers with leading zeros?
Hello! I am stepping on the same rake that I have already defeated in Excel - the problem with incorrect display of long numbers, where some of them may be with leading zeros.
Earlier, somewhere in the forums, I found a certain cell format in order to correctly display long numbers with leading zeros, a couple of months passed and I forgot how to set this format. And today I’ve been looking for this format for a long time and now I’m asking my first question in the Toaster :)
Maybe someone works in Excel more often and can tell you what format to set in the Excel cell format.
Do not offer options with an apostrophe or any other character at the beginning and the "Text" cell format, it is the custom option that is set in "Cell Format" - "All formats", which solves two problems at once:
1) Correct display of long numbers
2) Correct display of numbers with leading zeros
There is also an option to collect the Excel HTML file and add the .text style, but in this case the question is in the format that is set in Excel itself.
Примеры стили:
.num {
mso-number-format:General;
}
.text{
mso-number-format:"\@";/*force text*/
}
В тэгах:
<td class="num">34</td>
<td class="num">17.0</td>
<td class="text">067</td>
Answer the question
In order to leave comments, you need to log in
000 000 000 000
if you need it wrong, finish it yourself: https://www.planetaexcel.ru/techniques/9/72/
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question