Tornado API Library - V12.30.08

z.dbNameMap Property

NameMap for the Grid. Rename the field names in the header display and optionally supply the calculated expression required for sort, edit and filter criteria.

Product Version

EP, Gold

Property Value

Obj.dbNameMap="(;,)Field |Alias | Tag=HeaderTags | Formula=CalcExp, ...repeat"

FieldField name or ordinal number of Grid or Form to be mapped. Field=CustomerID , Field=0
AliasThe mapped name. Alias=My Name
TagClass=?? COLSPAN=?? Align=??. Due to the new structure of being able to replace the entire header with GH1 and header=false. Tag use is not effective here. Selecting a new class will change the appearance of the cell.
FormulaThis optional parameter defines the calculated expression of the field. This parameter is required for sort, filtering and editing criteria. See following case study examples. Note that the formula field must provide the appropriate wrappers for alias fields of SQL, ORACLE etc..

QuickProp Keyword Abbreviation



The TextHolder - GH1 tag enables user to supply a fully customized header. Therefore the namemap feature in Tornado is effective mostly in assigning a formula to the calculated field.


<script language="VB" runat="server">
Sub Page_Load(Src As Object, E As EventArgs)
Dim E2 As New Tornado.z
With E2
   .dbQP = "U=2|M=Dh|S=Party|Ps=13|gdf=0,1,2|D=NWIND|Q=Orders|" & _
     Th=Ti=Debug Demo|de=Fields"
   .dbNameMap = "field=OrderID|alias=MyID, field=CustomerID|" & _
End With
End Sub
<script language="VB" runat="server">
Sub Page_Load(Source as Object, E as EventArgs)
  Dim E64 As New Tornado.Z()
    With E64
     .dbNameMap = "field=3|Alias=Triple|Formula=CustomerID + CompanyName + CustomerID"
     .dbSQL = "SELECT CustomerID, CompanyName, ContactName, CustomerID + " & _
       "CompanyName + CustomerID as 'Dummy' FROM Customers"
     .dbTextHolder = "Title=Simple NameMap"
    End With
End Sub

See Also

z Class | Tornado Namespace | dbFormNameMap | dbEmbeddedGridNameMap | Special Topic - NameMap