XBROWSE Column Question

Re: XBROWSE Column Question

Postby nageswaragunupudi » Wed May 10, 2023 12:28 am

how is the Syntax to use "Header - click" to SET Order / TAG :?:

Set
Code: Select all  Expand view
oBrw:lAutoSort := .t.  // default .f.

to invoke autosort feature.
We can also use AUTOSORT clause in the XBROWSE command, which sets the flag.
When autosort flag is ON, XBrowse automatically sorts the data on click of header, using the value in oCol:cSortOrder.
First click on the header sorts the data in ascending order.
Second click on the header sorts the data in descending order. In case of DBF, it uses the RDD function OrdDescend()

If oCol:cSortOrder is empty XBrowse does not attempt to sort.
Note: FWH2304 provides a way to sort such columns too. We discuss it in another topic.
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10620
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: XBROWSE Column Question

Postby nageswaragunupudi » Wed May 10, 2023 12:42 am

when usig OrdWildSeek() in XBROWSE how to "continue" :?:
i did not found a 2nd OrdWildSeek() or a loop


No need for 2nd call or loop.
Code: Select all  Expand view
OrdWildSeek(oBrw:cSeek, oBrw:lSeekNext )
works for first seek and SeekNext automatically.

Note:Syntax
Code: Select all  Expand view
OrdWildSeek( cSeek, [lFromNextRec], [lBakwards]) --> lFound


Inspired by your postings, we introduced automatic SeekNext by pressing F3 key from FWH2304.
As of now, this works for arrays, DBF, TDatabase, all ADO rdbms, FW MySql. Yet to implement for dolphin,tmysql,eagle1,postgre, etc.
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10620
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: XBROWSE Column Question

Postby Marc Venken » Wed May 10, 2023 7:20 am

Here is a sample for ordwildseek. It's new to me....

viewtopic.php?f=3&t=39965
Marc Venken
Using: FWH 23.04 with Harbour
User avatar
Marc Venken
 
Posts: 1425
Joined: Tue Jun 14, 2016 7:51 am
Location: Belgium

Re: XBROWSE Column Question

Postby nageswaragunupudi » Wed May 10, 2023 7:50 am

Marc Venken wrote:Here is a sample for ordwildseek. It's new to me....

viewtopic.php?f=3&t=39965


Mr. Venken
OrdWildSeek( cSeek, ... ) is actually an (x)Harbour function in DBFNTX and DBFCDX RDDs, applicable for indexed DBFs.
We can seek expressions like "*A?C"

The above post refers to similar functionality we created in FWMaria library for MySql tables.
In fact, there was not problem that was solved in the post. He was not aware that we already implemented and we just clarified that it was implemented and working ok
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10620
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: XBROWSE Column Question

Postby Jimmy » Wed May 10, 2023 6:24 pm

hi,
nageswaragunupudi wrote:
Code: Select all  Expand view
oBrw:lAutoSort := .t.  // default .f.

to invoke autosort feature.
We can also use AUTOSORT clause in the XBROWSE command, which sets the flag.

WOW, that is nice :D

nageswaragunupudi wrote:When autosort flag is ON, XBrowse automatically sorts the data on click of header, using the value in oCol:cSortOrder.
First click on the header sorts the data in ascending order.
Second click on the header sorts the data in descending order. In case of DBF, it uses the RDD function OrdDescend()

If oCol:cSortOrder is empty XBrowse does not attempt to sort.
Note: FWH2304 provides a way to sort such columns too. We discuss it in another topic.

ah, i did not know OrdDescend() as Xbase++ does not have it
greeting,
Jimmy
User avatar
Jimmy
 
Posts: 1725
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany

Re: XBROWSE Column Question

Postby Jimmy » Wed May 10, 2023 6:29 pm

hi,
nageswaragunupudi wrote:No need for 2nd call or loop.
Code: Select all  Expand view
OrdWildSeek(oBrw:cSeek, oBrw:lSeekNext )
works for first seek and SeekNext automatically.

Note:Syntax
Code: Select all  Expand view
OrdWildSeek( cSeek, [lFromNextRec], [lBakwards]) --> lFound

but how can it continue without press a Key :?:

nageswaragunupudi wrote:Inspired by your postings, we introduced automatic SeekNext by pressing F3 key from FWH2304.

Yes, that would be fine, thx
greeting,
Jimmy
User avatar
Jimmy
 
Posts: 1725
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany

Re: XBROWSE Column Question

Postby nageswaragunupudi » Wed May 10, 2023 7:01 pm

but how can it continue without press a Key :?:

SeekNext is performed when F3 key is pressed by the user.
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10620
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: XBROWSE Column Question

Postby Jimmy » Wed May 10, 2023 7:22 pm

hi,
nageswaragunupudi wrote:
but how can it continue without press a Key :?:
SeekNext is performed when F3 key is pressed by the user.

this is for "new" Version or include in older Version 2022/07 also :?:

i do have a Buttonbar where i have F3
will it "override" F3 "internal" :?:
greeting,
Jimmy
User avatar
Jimmy
 
Posts: 1725
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany

Re: XBROWSE Column Question

Postby nageswaragunupudi » Wed May 10, 2023 7:45 pm

SeekNext is implemented in FWH2304 which is triggered by F3.
It is not there in previous versions.

This is triggered when oBrw window receives WM_KEYDOWN message with F3 key.
(i.e., it is implemented in oBrw:KeyDown() method)
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10620
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Previous

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 46 guests