سؤال

I'd like to be able to align the tabstops I use in a StringFormat (set with the SetTabStops() method)

Is this possible?

هل كانت مفيدة؟

المحلول

See (Update: Didn't help much as per comments below)


Or, as I commented further and recommend by yourself :)

In String.Format I don't think so as all it specializes in is replacing {n} parts with different formatters. One thing you may be able to do is to split the string by '\t', and apply .PadLeft() or .PadRight() to each and then string.Join() them, or use any of the suggestions above, but, string.Format is likely dead end for this one.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top