GoDigram for .NET Framework and .NET Core
Northwoods.Go.Xml Namespace
/
GoXmlTransformer Class
/ Int32FromString Method
the string to parse
the default value to return if the string is null or there is a syntax or range error
Collapse All
Expand All
Language Filter: All
Language Filter: Multiple
Language Filter: Visual Basic
Language Filter: C#
C#
In This Topic
Int32FromString Method
In This Topic
Parse a string value as an integer.
Syntax
C#
public
int
Int32FromString(
string
str
,
int
def
)
Parameters
str
the string to parse
def
the default value to return if the string is null or there is a syntax or range error
Return Value
An integer parsed from the string
str
; if there is a parsing exception, this method returns the value of
def
.
Remarks
You can convert a value to a string by calling
WriteAttrVal(String,Int32)
and passing null as the first argument (the attribute name).
See Also
Reference
GoXmlTransformer Class
GoXmlTransformer Members