This topic has not yet been rated - Rate this topic

PrivateObject.GetField Method (String, BindingFlags)

Gets a value from a named field, based on the name and lookup mask.

Namespace:  Microsoft.VisualStudio.TestTools.UnitTesting
Assembly:  Microsoft.VisualStudio.QualityTools.UnitTestFramework (in Microsoft.VisualStudio.QualityTools.UnitTestFramework.dll)
public Object GetField(
	string name,
	BindingFlags bindingFlags
)

Parameters

name
Type: String

The name of the private field to get.

bindingFlags
Type: BindingFlags

Return Value

Type: Object
The value set for the name field.
ExceptionCondition
ArgumentException

name is null or empty.

Did you find this helpful?
(1500 characters remaining)
© 2013 Microsoft. All rights reserved.