I have a piece of code that automatically removes all the dashes if the ID isn't null. It was brought to my attention that these also need to always have 9 numbers. However when you lead with zeros the 0's are automatically cut off. How do I add another condition to the id. Something like
if i.id.length < 9 add 0's to the front until it equals 9?
Original code
retval.Add(new SpreadsheetColumnSetup<Row>("ID", i =>
(i.Id == null)
? i.Id
: i.Id.Replace("-", "")));