Size3D.Parse(String) 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
public:
static System::Windows::Media::Media3D::Size3D Parse(System::String ^ source);
public static System.Windows.Media.Media3D.Size3D Parse (string source);
static member Parse : string -> System.Windows.Media.Media3D.Size3D
Public Shared Function Parse (source As String) As Size3D
参数
返回
等效的 Size3D 结构。
示例
以下示例演示如何将字符串表示形式 Size3D 转换为 Size3D 结构。
// Converts a string representation of a 3-D size into a Size3D structure.
Size3D sizeResult = new Size3D();
sizeResult = Size3D.Parse("10,20,30");
// sizeResult is equal to (10,20,30)
// Displaying Results
syntaxString = "sizeResult = Size3D.Parse(\"10,20,30\");";
resultType = "Size3D";
operationString = "Converting a string into a Size3D structure";
ShowResults(sizeResult.ToString(), syntaxString, resultType, operationString);
' Converts a string representation of a 3-D size into a Size3D structure.
Dim sizeResult As New Size3D()
sizeResult = Size3D.Parse("10,20,30")
' sizeResult is equal to (10,20,30)
' Displaying Results
syntaxString = "sizeResult = Size3D.Parse(""10,20,30"")"
resultType = "Size3D"
operationString = "Converting a string into a Size3D structure"
ShowResults(sizeResult.ToString(), syntaxString, resultType, operationString)