ITabView.DisplayAccessRights

Syntax

DisplayAccessRights: Boolean;

DisplayAccessRights: boolean;

Description

The DisplayAccessRights property determines whether the icons () showing access permissions are to be displayed.

Comments

Available values:

For details about displaying data access permissions as icons see the Displaying Data Access Permissions as Icons section.

Example

 

Executing the example requires a form, the Button component named Button1 on the form, the TabSheetBox component named TabSheetBox1 and the UiReport component named UiReport1 that is a data source for TabSheetBox (for Fore.NET example use the TabSheetBoxNet component named TabSheetBoxNet1 and the UiReportNet component named UiReportNet1). A regular report should be loaded to UiReport1.

Add links to the system assemblies:

The example will be executed on clicking the button implemented in the Button component named Button1.

Sub Button1OnClick(Sender: Object; Args: IMouseEventArgs);
Var
    Report: IPrxReport;
    TabView: ITabView;
Begin 
    
//Activate component to get access to data
    UiReport1.Active:=True;
    
//Determine regular report connected to component
    Report := UiReport1.Report;
    
//Get spreadsheet view
    TabView := (Report.ActiveSheet As IPrxTable).TabSheet.View;
    
//Enable displaying access permission icons
    TabView.DisplayAccessRights := True;
End Sub Button1OnClick;

Imports System.Windows.Forms;
Imports Prognoz.Platform.Forms.Net;
Imports Prognoz.Platform.Interop.Report;
Imports Prognoz.Platform.Interop.Tab;

Private Sub button1_Click(sender: System.Object; e: System.EventArgs);
Var
    Report: IPrxReport;
    TabView: ITabView;
Begin 
    
//Activate component to get access to data
    UiReportNet1.Active:=True;
    
//Determine regular report connected to component
    Report := UiReportNet1.ReportUi.Report;
    
//Get spreadsheet view
    TabView := (Report.ActiveSheet As IPrxTable).TabSheet.View;
    
//Enable displaying access permission icons
    TabView.DisplayAccessRights := True;
End Sub;

After executing the example the form displays a data table. Table cells will display access permission icons () if the user does not have permissions to edit data in these cells.

See also:

ITabView | IPrxReport