SPDataStore.ApplyUserPermissionsToDatasource Method

Applies the current user’s permissions to a retrieved data source by setting the ReadOnly property and connection string visibility.

Namespace:  Microsoft.PerformancePoint.Scorecards.Store
Assembly:  Microsoft.PerformancePoint.Scorecards.Store (in Microsoft.PerformancePoint.Scorecards.Store.dll)

Syntax

'Declaration
Public Function ApplyUserPermissionsToDatasource ( _
    datasource As DataSource _
) As DataSource
'Usage
Dim instance As SPDataStore
Dim datasource As DataSource
Dim returnValue As DataSource

returnValue = instance.ApplyUserPermissionsToDatasource(datasource)
public DataSource ApplyUserPermissionsToDatasource(
    DataSource datasource
)

Parameters

Return Value

Type: Microsoft.PerformancePoint.Scorecards.DataSource
A clone of the specified data source object with the ReadOnly property set accordingly and with the connection string masked out if the user does not have edit permissions.

Remarks

As a best practice, do not return a retrieved data source or expose its results directly to an external caller. Instead, call ApplyUserPermissionsToDatasource(DataSource) and pass in the retrieved data source. Then, return the results of ApplyUserPermissionsToDatasource(DataSource) to the external caller.

See Also

Reference

SPDataStore Class

SPDataStore Members

Microsoft.PerformancePoint.Scorecards.Store Namespace