HPROJECTVAR_ITERATOR TFormer_GetFirstProjectVarIt ( HTFORM  pInstance,
LPCSTR  pszProjectName,
ERRCODE *  peCode 
)

Returns an iterator pointing to the first DataField in the specified Project.

Returns:
- Iterator in case of success
- NULL in case of an error (check peCode in this case)
Parameters:
[in] pInstance The TFORMer-Instance provided by a previous call to TFormer_Init.
[in] pszProjectName The name of the Project within the Repository.
[out] peCode Error Code (ErrOk (0) in case of success)
Remarks:
Creates a new DataField iterator and sets its position to the first DataField in the Project specified by pszProjectName. If pszProjectName is NULL or empty the DataField of the global Project are iterated. To get the name of the DataField call TFormer_ProjectVarItGetName.
Note:
Release the iterator after use with TFormer_FreeProjectVarIt! Memory leaks may occur otherwise.

This example iterates all DataFields within the project.
 // get iterator
 it = TFormer_GetFirstProjectVarIt (hTForm, lpszProjectName, &eCode);
 
 // iterate all DataFields
 while ((it != NULL) && (eCode == ErrOk))
 {
   // check, whether the DataField is editable
   eVarUsage = TFormer_ProjectVarItGetUsage (hTForm, it, &eCode);      
   if ((eVarUsage == eVarUsage_Normal) && (eCode == ErrOk))
   {
     // do something
   }   
   // get next DataField
   eCode = TFormer_GetNextProjectVarIt (it);
 }
 // release iterator
 TFormer_FreeProjectVarIt (it);
See also:
TFormer_GetNextProjectVarIt, TFormer_ProjectVarItGetUsage


© 2006-2009 - all rights reserved by TEC-IT Datenverarbeitung GmbH
Generated on Wed Sep 2 16:01:09 2009 for TFORMer Runtime DLL/Shared Library with doxygen 1.5.8