Click or drag to resize

imbEnumExtendBasegetEnumByName Method

imbSCI | imbACE | imbNLP | imbWEM | imbWBI
Na osnovu zadatog tipa i imena vraća instancu enumeracijije. Ako ne može da pronađe po imenu onda vraća prvu

Namespace:  imbSCI.Core.extensions.enumworks
Assembly:  imbSCI.Core (in imbSCI.Core.dll) Version: 0.3.58.
Syntax
C#
public static Object getEnumByName(
	this Type EnumType,
	string name,
	Object valueOnFail = null
)
Request Example View Source

Parameters

EnumType
Type: SystemType
Tip koji je enumeracija
name
Type: SystemString
String ime enumeration člana
valueOnFail (Optional)
Type: SystemObject

Return Value

Type: Object
Enumeracija - instanca

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type Type. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
See Also