PC SOFT

ONLINE HELP
FOR WINDEV, WEBDEV AND WINDEV MOBILE

Home | Sign in | English US
  • Use conditions
  • The different types of column subscripts
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
Returns the name of a column found in a Table or Treeview Table control.
Versions 16 and later
WINDEVLinux This function is now available for the WINDEV applications in Linux.
New in version 16
WINDEVLinux This function is now available for the WINDEV applications in Linux.
WINDEVLinux This function is now available for the WINDEV applications in Linux.
Versions 18 and later
WEBDEV - Server codePHP This function can now be used to handle the TreeView Table controls in the WEBDEV and PHP sites.
New in version 18
WEBDEV - Server codePHP This function can now be used to handle the TreeView Table controls in the WEBDEV and PHP sites.
WEBDEV - Server codePHP This function can now be used to handle the TreeView Table controls in the WEBDEV and PHP sites.
Versions 20 and later
Android This function is now available for the Android applications.
iPhone/iPad This function is now available for the iPhone/iPad applications.
New in version 20
Android This function is now available for the Android applications.
iPhone/iPad This function is now available for the iPhone/iPad applications.
Android This function is now available for the Android applications.
iPhone/iPad This function is now available for the iPhone/iPad applications.
Example
// Name of third column found in the "TABLE_ProductTable" control
ResColumnName = TableEnumColumn(TABLE_ProductTable, 3)
Versions 21 and later
WINDEViPhone/iPad
// Handle the column via a Control variable
pCol is Control
pCol <- TableEnumColumn(TABLE_ProductTable, 3)
New in version 21
WINDEViPhone/iPad
// Handle the column via a Control variable
pCol is Control
pCol <- TableEnumColumn(TABLE_ProductTable, 3)
WINDEViPhone/iPad
// Handle the column via a Control variable
pCol is Control
pCol <- TableEnumColumn(TABLE_ProductTable, 3)
Versions 21 and later
WINDEViPhone/iPad
// Enumerate all columns found in the "TABLE_ProductTable" control
AColumn is Control
FOR nColumn = 1 _TO_ TableCount(TABLE_ProductTable, toColumn)
AColumn <- TableEnumColumn(TABLE_ProductTable, nColumn)
Trace(AColumn..FullName+"//"+AColumn..Title)
END
New in version 21
WINDEViPhone/iPad
// Enumerate all columns found in the "TABLE_ProductTable" control
AColumn is Control
FOR nColumn = 1 _TO_ TableCount(TABLE_ProductTable, toColumn)
AColumn <- TableEnumColumn(TABLE_ProductTable, nColumn)
Trace(AColumn..FullName+"//"+AColumn..Title)
END
WINDEViPhone/iPad
// Enumerate all columns found in the "TABLE_ProductTable" control
AColumn is Control
FOR nColumn = 1 _TO_ TableCount(TABLE_ProductTable, toColumn)
AColumn <- TableEnumColumn(TABLE_ProductTable, nColumn)
Trace(AColumn..FullName+"//"+AColumn..Title)
END
Syntax
<Result> = TableEnumColumn(<Table Control> , <Column Subscript>)
<Result>: Character string
  • Name of column.
    Versions 21 and later
    WINDEViPhone/iPad This result can be assigned to a Control variable.
    New in version 21
    WINDEViPhone/iPad This result can be assigned to a Control variable.
    WINDEViPhone/iPad This result can be assigned to a Control variable.
  • Empty string ("") if <Column Subscript> is equal to the number of columns in the Table control + 1.
<Table Control>: Control name
Name of Table control to use.
If this parameter corresponds to an empty string (""), the Table control to which the current process belongs will be used.
<Column Subscript>: Integer
Subscript of the column, included between 1 and the number of columns found in the Table control + 1.
A WLanguage error occurs if this parameter is greater than the number of columns found in the Table control + 1.
To find out the number of columns in a Table control, use TableCount.
Remarks

Use conditions

TableEnumColumn can be used on:
  • a browsing or memory control,
  • a single-selection or multi-selection control,
WEBDEV - Server codePHP Reminder: The multi-selection controls are available in Ajax only.
WEBDEV - Server codePHP Reminder: The multi-selection is not available for the "standard" Table controls.

The different types of column subscripts

Two types of subscripts are available for the columns:
  • Subscript of the visible position: subscript of the column when running the window.
  • Creation subscript: subscript of the column when creating the control in the window editor.
These two types of subscripts are returned by TableColumnSubscript.
These subscripts are different if the columns have been moved by the user.
TableEnumColumn is using the creation subscript of the column.
Components
WINDEVReports and Queries wd230obj.dll
WEBDEV - Server code wd230page.dll
Windows Mobile wp230obj.dll
Java wd230java.jar
Linux wd230obj.so
Android wd230android.jar
Minimum required version
  • Version 9
This page is also available for…
Comments
Tabela , Saber quantas e nome das colunas
n_numero_colunas is int=TableCount(TABLE_pedido,toColonne)
FOR x=1 TO n_numero_colunas
s_nome_coluna is string=TableEnumColumn(TABLE_pedido,x)
Trace("Numero Coluna:"+x+CR+"Nome coluna:"+s_nome_coluna)
END

//Blog com Video e exemplo
http://windevdesenvolvimento.blogspot.com.br/2016/04/curso-windev-tabela-021-saber-quantas-e.html
De matos AMARILDO
Apr. 19 2016