PC SOFT

ONLINE HELP
FOR WINDEV, WEBDEV AND WINDEV MOBILE

Home | Sign in | English US
  • Combining the filters
  • Browsing a filtered access
  • Deleting one or more filters
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
Warning
From version 16, this feature is no longer available.
Filters the records of an access to one of the Palm Pilot databases (notepad, task list, address book or calendar).
Example
// Display the messages in a table (TABLE_MyTable) according to
// the category selected in a combo box (COMBO_Category)

// --- Initialization code of the combo box
ListAdd(COMBO_Category, "All the categories")
ListAdd(COMBO_Category, PalmListCategory())

// --- Whenever COMBO_Category is modified
IF COMBO_Category = "All the categories" THEN
// Deletes the filter on categories
PalmFilter(palmFCategory)
ELSE
PalmFilter(palmFCategory, COMBO_Category)
END
// Browses all the records and fills the table
TableDeleteAll(TABLE_MyTable)
MyMemo = PalmReadFirst()
WHILE NOT PalmOut()
TableAdd(TABLE_MyTable, MyMemo)
MyMemo = PalmReadNext()
END
Syntax
PalmFilter([<Access Name> [, <Type of Filter> [, <Filter Condition>]]])
<Access Name>: Optional character string (with quotes)
Name of access that was defined by PalmLoad. If this parameter is not specified or if it corresponds to an empty string (""), the last access handled by a PALM function is used.
<Type of Filter>: Optional integer constant
Type of filter that will be applied to the records corresponding to the specified access:
palmFCategoryFilters the records according to the category specified in <Filter Condition>.
This filter can be applied to all the Palm databases except the Calendar database.
palmFMemoContentFilters the records according to a word found in the memo (including the first line). This word must be specified in <Filter Condition>. This filter can be applied to the Notepad database only.
palmFMemoSubjectFilters the records according to a word found in the first line of the memo. This word must be specified in <Filter Condition>. This filter can be applied to the Notepad database only.
<Filter Condition>: Optional character string (with quotes)
Condition corresponding to the type of filter (<Type of Filter>). This parameter can correspond to:
  • a category name (palmFCategory constant).
  • a character string to find in the memo (palmFMemoSubject or palmFMemoContent constant). Caution: the filtering performed on a word is not case sensitive: the specified word will be sought regardless of the case.
If this parameter is not specified or if it corresponds to an empty string (""), the specified filter is deleted for the access used. The other specified filters remain valid.
Remarks

Combining the filters

  • The different types of filters can be simultaneously applied to the same access. This enables you to filter an access to the notepad both on a category and on a word found in the memo. The selected records will correspond to the two criteria.
    PalmFilter must be used as many times as necessary.
    For example, the following code is used to find out in the "MYACCESS" access the records corresponding to the "Work" category and containing the "07/23/01" date:
    PalmFilter("MYACCESS", palmFCategory, "Work")
    PalmFilter("MYACCESS", palmFMemoContent, "07/23/01")
  • The records cannot be filtered according to several categories or according to several keywords.

Browsing a filtered access

If the access is filtered, the filter is taken into account by the different functions for browsing the records. Therefore:
  • PalmReadFirst is used to read the first record corresponding to the filter.
  • PalmReadNext and PalmReadPrevious are used to respectively read the next record and the previous record corresponding to the filter.
  • PalmReadLast is used to read the last record corresponding to the filter.
  • PalmNbRec is used to find out the number of records corresponding to the filter.

Deleting one or more filters

  • The following syntax allows you to delete all the filters for the last access used: PalmFilter()
  • The following syntax allows you to delete all the filters for a specific access: PalmFilter(<Access Name>)
  • The following syntax allows you to delete a type of filter for the last access used: PalmFilter(<Type of Filter>)
  • The following syntax allows you to delete a type of filter on a specific access: PalmFilter(<Access Name>, <Type of Filter>)
Components
WINDEVReports and Queries wd230plm.dll
Linux wd230plm.so
Minimum required version
  • Version 9
This page is also available for…
Comments
Click [Add] to post a comment