Search Results for

    Show / Hide Table of Contents

    TfrxReportServer

    TfrxReportServer

    TfrxReportServer component plays the role of a report server and HTTP server. This component does not require any additional components.

    TfrxReportServer class inherited from TComponent

    Properties

    Name Type Description
    Active Boolean the value, which indicates activity of the server. It may be used for starting the server by setting a value in "True"
    Configuration TfrxServerConfig server configuration (TfrxServerConfig class is described below). Configuration changes become active only after you restart the server
    AllowIP TStrings list of authorized IP addresses. The format of the list is as following: one line contains one IP address. In cases when the server does not find a client's address in this list, the client will be forbidden to connect; if the list is empty, all addresses are allowed to connect
    DenyIP TStrings list of IP addresses forbidden to connect. The format of the list is as following: one line contains one IP address. In cases when the server does not find a client's address in this list, the client will be forbidden to connect; if the list is empty, all addresses are allowed to connect
    PrintPDF Boolean pressing the "print" button in navigator's control panel (when viewing the resulting pages in a web browser) creates a PDF file, if this value is set to True. Otherwise, standard print action of the browser will be executed. Default setting is "True"

    The following properties are inaccessible in object's inspector, but it is possible to access them from the code:

    Name Type Description
    Statistic TfrxServerStatistic server statistics (TfrxServerStatistic is described below)
    Totals TStrings readable form of server statistics information
    Variables TfrxServerVariables internal server variables (TfrxServerVariables is described below)

    Methods

    Method Description
    constructor Create(AOwner: TComponent) creation of an object
    procedure Open startup of the server. At this moment all changes of configuration would be activated
    procedure Close server shutdown

    Event handlers:

    OnGetReport: TfrxServerGetReportEvent - may be used for loading the reports from any places (BLOB fields, files from any folders etc).

    Type of the handler:

    TfrxServerGetReportEvent = procedure (ReportName: String; Report: TfrxReport) of object;
    

    ReportName - name of the requested report; it may be used for identification of a specific report;

    Report - an instance of the TfrxReport object, to which the report should be loaded.

    OnGetVariables: TfrxServerGetVariablesEvent - can be used for manual processing of the parameters received from the client, as well as execution of any operations directly on a server.

    TfrxServerGetVariablesEvent = procedure(const ReportName: String; Variables: TfrxVariables) of object;
    

    ReportName - The name of the report transferred in query. It can be used for filtering one or another parameter directly in the handler;

    Variables - The list of the parameters received from the client.

    TfrxServerConfig class inherited from TPersistent

    Object of this class contains information about server configuration.

    Properties

    Name Type Description
    Port Integer TCP/IP port number for client connection, default value is 80
    IndexFileName String default filename, if the filename field in HTTP query is empty. Default value is 'index.html'
    SessionTimeOut Integer time of storing report results on the server (in seconds). Default value is 300. As soon as the default time expires, the report results will be deleted. It is set depending on specificities of created reports and methods of client-server interaction; the waiting time of client activity after his connection in seconds, the default value is 60, after this time the client session will be deleted
    SocketTimeOut Integer timeout of waiting for client's response (in seconds). Default value is 60. When time expires, the session will be terminated
    Logging Boolean log writing, "True" - enabled, "False" - disabled, "True" is set by default
    LogPath String path to folder with logs; current folder by default
    ReportPath String path to folder with reports; current folder by default
    RootPath String path to folder with HTML files and reports results
    Login String user name for authentication. If line is empty - authentication is not required. Empty line is a default setting
    Password String password for authentication, empty line by default
    Compression Boolean compression of transferred documents, client support required; "True" by default
    MIC Boolean Message Integrity Checksum using MD5 algorithm. "True" by default
    NoCacheHeader Boolean document is not cached by client, "True" by default
    OutputFormats TfrxServerOutputFormats supported formats for requested reports, one or more from set (sfHTM, sfXML, sfXLS, sfRTF, sfTXT, sfPDF, sfJPG, sfFRP). By default, all elements of set are included
    ReportCaching Boolean enable the reports cache on a server
    ReportCachePath String path to a folder with reports cache
    DefaultCacheLatency Integer reports in cache default storage time (in seconds)

    Methods

    Method Description
    procedure LoadFromFile(const FileName: String) loads configuration from a file
    procedure SaveToFile(const FileName: String) saves configuration to a file

    TfrxServerStatistic class inherited from TPersistent

    Properties

    Name Type Description
    CurrentReportsCount Integer number of reports currently build
    CurrentSessionsCount Integer number of sessions currently connected
    MaxReportsCount Integer maximum number of reports simultaneously built
    MaxSessionsCount Integer maximum number of sessions simultaneously connected
    TotalErrors Integer number of errors
    TotalReportsCount Integer number of reports
    TotalSessionsCount Integer number of sessions
    UpTimeDays Integer Uptime days
    UpTimeHours Integer Uptime hours
    UpTimeMins Integer Uptime minutes
    UpTimeSecs Integer Uptime seconds

    TfrxServerVariables class inherited from TCollection

    Contains server variables.

    Used (reserved) names of the variables will describe in the part 3.4.

    Methods

    Method Description
    function GetValue(const Name: String): String returns value of the variable with Name
    procedure AddVariable(const Name: String; const Value: String) adds a variable with Name and Value
    Back to top © Copyright Fast Reports Inc.