Subject | RE: [IBO] Incremental searching on descending OrderingItems does not work |
---|---|
Author | Michael L. Horne |
Post date | 2001-02-22T22:49:28Z |
Hello
Jason, this seems to be a problem to me, even though we can use
the NEG value to start with this doesn't fix the problem. There
are many times when my users want to see the data in descending
order, and are rarely interested in seeing the data in ascending
order.
I haven't ran into this problem yet, but I am about to start on
that section of the conversion where I would need to order the
data in descending order, and perform incremental searching.
Is there any way around this problem?
Here is a Work Around/Solution,
1. Define a tEdit, with a OnChange Event.
2. Within the OnChange Event
query.Locate(query.SearchingLink, edLocate.Text, [lopPartialKey]);
3. You may want to create a OnOrderingChange Event for the
query with:
edLocate.Text := '';
This seems to work with the query in both ascending & descending
orders. Not as easy to use as the TIB_IncSearch but it gets the
job done.
Below is the full code for my OnChange Event:
if (edLocate.Text <> '') then
begin
if Assigned( qyNetComIn.OrderingField ) and
qyNetComIn.OrderingField.IsText then
begin
qyNetComIn.Locate(qyNetComIn.SearchingLink, edLocate.Text,
[lopPartialKey]);
end;
end else begin
qyNetComIn.First
end;
Good Luck
Michael L. Horne
Jason, this seems to be a problem to me, even though we can use
the NEG value to start with this doesn't fix the problem. There
are many times when my users want to see the data in descending
order, and are rarely interested in seeing the data in ascending
order.
I haven't ran into this problem yet, but I am about to start on
that section of the conversion where I would need to order the
data in descending order, and perform incremental searching.
Is there any way around this problem?
Here is a Work Around/Solution,
1. Define a tEdit, with a OnChange Event.
2. Within the OnChange Event
query.Locate(query.SearchingLink, edLocate.Text, [lopPartialKey]);
3. You may want to create a OnOrderingChange Event for the
query with:
edLocate.Text := '';
This seems to work with the query in both ascending & descending
orders. Not as easy to use as the TIB_IncSearch but it gets the
job done.
Below is the full code for my OnChange Event:
if (edLocate.Text <> '') then
begin
if Assigned( qyNetComIn.OrderingField ) and
qyNetComIn.OrderingField.IsText then
begin
qyNetComIn.Locate(qyNetComIn.SearchingLink, edLocate.Text,
[lopPartialKey]);
end;
end else begin
qyNetComIn.First
end;
Good Luck
Michael L. Horne
> -----Original Message-----actually be ascending and the second must be descending.
> From: Jason Wharton [mailto:jwharton@...]
> Sent: Thursday, February 22, 2001 3:37 PM
> To: IBObjects@yahoogroups.com
> Subject: Re: [IBO] Incremental searching on descending OrderingItems
> does not work
>
>
> There is a simple way.
>
> Put an entry for both Ascending and Descending and then set the
> OrderingItemNo to the negative so that it will start up in the descending
> order.
> It is intended to work this way. The first entry in that item must
>
> Jason Wharton
> CPS - Mesa AZ
> http://www.ibobjects.com
>
>
> ----- Original Message -----
> From: "Jörg Schiemann" <schimmi@...>
> To: <IBObjects@yahoogroups.com>
> Sent: Thursday, February 22, 2001 12:23 PM
> Subject: Re: [IBO] Incremental searching on descending OrderingItems does
> not work
>
>
> > I want that the grid start with descending ordering.
> >
> > Is it possible to start the grid with ascending ordering and
> > then simulate the mouseclick on the columnlabel?
> >
> > Or is there another way?
> >
> > Regards,
> > Jörg Schiemann
>
>
>
>
>
>
> Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
>
>