Skip to content

DataFlexTableName - cDRReport

Methods - Properties - Events

Method Type

Function

Return Type

String

Arguments

Argument Description
hTable Handle to an opened database table in the application.

Description

Returns the name of a table according to the DataFlex application. Functionality is different per connectivity kit.

Database Driver Returned value
DATAFLEX The filelist root name (DF_FILE_ROOT_NAME attribute)
MSSQLDRV The table name used in the SQL database (DF_FILE_TABLE_NAME attribute)
DB2_DRV The table name used in the SQL database (DF_FILE_TABLE_NAME attribute)
ODBC_DRV The table name used in the SQL database (DF_FILE_TABLE_NAME attribute)
DFBTRDRV The filelist logical name (DF_FILE_LOGICAL_NAME attribute)

The table number passed to the function must be OPENED before. The name of the connectivity kit is retrieved via the DF_FILE_DRIVER attribute.

The function can be augmented or overwritten in a subclass or object.

DataFlex Framework usage

  • Web
  • Windows
  • FlexTron

Sample

Object oReport is a cDRReport
    Set psReportName to 'MyReport.dr'
End_Object

Object oRunReportButton is a Button
    Set Label to 'Run Report'

    Procedure OnClick
        String sReportId sFileListName

        Get OpenReport of oReport to sReportId
        If (sReportId <> '') Begin
            Get DataFlexTableName of oReport Customer.File_Number to sName
            Send CloseReport of oReport sReportId
        End        
    End_Procedure
End_Object