Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Set Filter to can do the most.
Message
From
19/09/2005 23:43:16
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
 
 
To
19/09/2005 22:47:17
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
01051118
Message ID:
01051128
Views:
8
>Hi all,
>
>I'm wondering how far set filter to in VFP can do the most like in Excel :
>
>Because in Excel we can set filter to any fields in the sheet, can we do the same thing with VFP ?.
>
>Please give the advices , really appreciated in advance.
>TIA

You can put the filter to any condition on a table. The condition can involve one field, or even not name any field at all, such as a filter that involves deleted() or recno().

For example (in a DBF that contains a list of people):
set filter to LastName = "P" && starts with "P"

set filter to Age <= 40

set filter to LastName = "P" and age <= 40 && combined condition

set filter to recno() % 100 = 0 && gets a sample: one in every 100 records

set filter to "x" $ LastName && LastName contains an "x"
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Previous
Reply
Map
View

Click here to load this message in the networking platform