PC SOFT

AYUDA EN LÍNEA
 WINDEVWEBDEV Y WINDEV MOBILE

  • Example: Describing a data file by programming
HDescribeFullTextIndex (Example)
Example: Describing a data file by programming
WINDEVWEBDEV - Server codeReports and QueriesWindowsWindows MobileUser code (UMC) The following example is used to describe a data file by programming with its links, items, full-text indexes, ...
AFile is File Description
AnItem is Item Description
MyFullTextIndex is IndexFullText Description
CUSTOMER is Data Source
 
// Describe the "CUSTOMER" file
AFile.Name = "CUSTOMER"
AFile.Type = hFileNormal
AFile.FicCryptMethod = hCryptStandard
 
// Describe the "LASTNAME" item
AnItem.Name = "LASTNAME"
AnItem.Type = hItemText
AnItem.Size = 40
AnItem.KeyType = hDuplicatesKey
HDescribeItem(AFile, AnItem)
 
// Describe the "FIRSTNAME" item
AnItem.Name = "FIRSTNAME"
AnItem.Type = hItemText
AnItem.Size = 40
HDescribeItem(AFile, AnItem)
 
// Describe the full-text index
MyFullTextIndex.MinimumLength = 4
MyFullTextIndex.Name = "MyFullTextIndex"
MyFullTextIndex.Items = "LASTNAME+FIRSTNAME"
MyFullTextIndex.AccentuationSensitive = True
MyFullTextIndex.CaseSensitive = False
HDescribeFullTextIndex(AFile, MyFullTextIndex)
 
// Validate the file description
HDescribeFile(AFile)
// Create the Customer file (recognized because declared as data source)
HCréation(CUSTOMER)
// Create a record
CUSTOMER.LASTNAME = "Doe"
CUSTOMER.FIRSTNAME = "Andrew"
HAdd(CUSTOMER)
// Create a record
CUSTOMER.LASTNAME = "Doe"
CUSTOMER.FIRSTNAME = "Vince"
HAdd(CUSTOMER)
Versión mínima requerida
  • Versión 14
Comentarios
Haga clic en [Agregar] para publicar un comentario