Open this page in the API Guide

CredentialContext.Execute<T> Method (Func<T>)

Executes the provided delegate under the context of the credentials.

Namespace:  Dundas.BI.Data.DataRetrieval
Assembly:  Dundas.BI.Core (in Dundas.BI.Core.dll) Version: 2.0.0.0 (25.1.0.1000)
Syntax
public virtual T Execute<T>(
	Func<T> func
)

Parameters

func
Type: System.Func<T>
The Func<T, TResult> to run.

Type Parameters

T
The type of the return value.

Return Value

Type: T
Exceptions
ExceptionCondition
ArgumentNullExceptionfunc is null.
Remarks
If IsContextLinkedToCurrentThread is true for the corresponding credential provider, any code which needs to be run under the context of the credentials must be done so using this method or one of its overloads.
See Also