dataview wildcard searches
From: John Hernry (john.henry_at_sasktel.com)
Date: 10/31/04
- Next message: Maarten: "Re: dataview wildcard searches"
- Previous message: Mark J. McGinty: "Re: how to use GetRows() with VBscrip (ASP)?"
- Next in thread: Maarten: "Re: dataview wildcard searches"
- Reply: Maarten: "Re: dataview wildcard searches"
- Messages sorted by: [ date ] [ thread ]
Date: Sun, 31 Oct 2004 10:33:47 -0700
I have a datagrid that is bound to a dataview. I am looking to create a
form that will perform wildcard searches on the dataview and move the
datagrid to the found row.
I can get the find to work in that it returns a valid row, but it is not the
first row with that value. I suspect that it is because it is not a unique
value in that column. I also can't perform wildcard searches.
Here is my search code
Dim dvData As DataView
Dim cmBkMrk As CurrencyManager
dvData = Me.dgrCatalogue.DataSource
dvData.Sort = "Artist"
cmBkMrk = Me.dgrCatalogue.BindingContext(dvData)
cmBkMrk.Position = dvData.Find("Triumph")
Me.dgrCatalogue.Select(cmBkMrk.Position)
If you have ever used the find in Access I am trying to build something
along that line. Where I can specify criteria such as: search in one field,
all fields, at the beginning of the field, end of the field, must match the
entire field, or case sensitive etc. My database currently has 30,000
records with 5 fields: ID, Source, Song, Artist, Album. ID is the primary
key.
I suspect that I am going to have to create a second dataview of the table,
do a filter on it, find the record I need (which will likely have to still
be done by looping through the filtered records, but at least far less of
them), get the unique ID from the found record then find that ID on the
displayed dataview and move to that record. . I was hoping for a quicker
method as this method will be slow.
Thank you in advance
John
- Next message: Maarten: "Re: dataview wildcard searches"
- Previous message: Mark J. McGinty: "Re: how to use GetRows() with VBscrip (ASP)?"
- Next in thread: Maarten: "Re: dataview wildcard searches"
- Reply: Maarten: "Re: dataview wildcard searches"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|
|