Size.ToString 方法

定义

返回一个表示此 String 实例的 SizeReturns a String that represents this instance of Size.

重载

ToString()

返回一个表示此 String 对象的 SizeReturns a String that represents this Size object.

ToString(IFormatProvider)

返回一个表示此 String 实例的 SizeReturns a String that represents this instance of Size.

ToString()

返回一个表示此 String 对象的 SizeReturns a String that represents this Size object.

public:
 override System::String ^ ToString();
public override string ToString ();
override this.ToString : unit -> string
Public Overrides Function ToString () As String

返回

用于指定后跟高度的宽度的 StringA String that specifies the width followed by the height.

注解

如果 @no__t 0 属性设置为30,并且 @no__t 属性设置为40,则 ToString 方法返回一个字符串,该字符串显示 @no__t。If the Width property is set to 30 and the Height property is set to 40, the ToString method returns a string that says "30, 40".

ToString(IFormatProvider)

返回一个表示此 String 实例的 SizeReturns a String that represents this instance of Size.

public:
 System::String ^ ToString(IFormatProvider ^ provider);
public string ToString (IFormatProvider provider);
override this.ToString : IFormatProvider -> string
Public Function ToString (provider As IFormatProvider) As String

参数

provider
IFormatProvider

一个对象,提供用于控制格式设置的方式。An object that provides a way to control formatting.

返回

一个 String,表示此 Size 对象。A String that represents this Size object.

适用于