This documentation is archived and is not being maintained.

StringFormat Class

Encapsulates text layout information (such as alignment and line spacing), display manipulations (such as ellipsis insertion and national digit substitution) and OpenType features. This class cannot be inherited.

For a list of all members of this type, see StringFormat Members.


[Visual Basic]
NotInheritable Public Class StringFormat
   Inherits MarshalByRefObject
   Implements ICloneable, IDisposable
public sealed class StringFormat : MarshalByRefObject, ICloneable,
public __gc __sealed class StringFormat : public
   MarshalByRefObject, ICloneable, IDisposable
public class StringFormat extends MarshalByRefObject implements
   ICloneable, IDisposable

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.


Many common formats are provided through the StringFormatFlags enumeration. StringFormat objects can be changed.


Namespace: System.Drawing

Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

Assembly: System.Drawing (in System.Drawing.dll)

See Also

StringFormat Members | System.Drawing Namespace