Solved

Searching a dbgrid

Posted on 2000-04-26
2
219 Views
Last Modified: 2010-04-04
I am using Delphi5 pro.
I am searching a dbgrid using the TDataset.Locate method.
How do I find the next occurance of the searched text after the first is located?

Thanks for your help,
Ivan
0
Comment
Question by:icarey
2 Comments
 
LVL 1

Accepted Solution

by:
msedi earned 100 total points
ID: 2750950
Hello,

as far as I know there's no possibility to go to the next record. Maybe you can use a filter and then step through all found items. Or you do it by hand with
 

  while (not Table.EOF) do
  begin
    // Search method here
    Table.Next;  
  end;

Good luck, Martin
0
 
LVL 1

Expert Comment

by:bozo7
ID: 2751279
Locate only finds the first occurence of the value. To do a find next you need to use TDataset.FindFirst then use TDataSet.FindNext.

Ross
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
I designed this idea while studying technology in the classroom.  This is a semester long project.  Students are asked to take photographs on a specific topic which they find meaningful, it can be a place or situation such as travel or homelessness.…

919 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now