I wish to write to a CSV file some data. One of the column that I input the information is in the form of an integer with leading zeros, example: 0000000013.
For some reason, excel 'converts' it to 13, and I must have it with 10 digits (0000000013). Can anyone tell how this can be circumvented?
String value = "0000000013"; //I tried String.format("%8d", 13) doesn't work
printWriter.println(value);
Thanks!!!
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…