xBrowse and SQLRDD bug
xBrowse and SQLRDD bug
Hi,
I would like to ask the status of the fix, as I reported the wrong behaviour in december.
Thank you.
I would like to ask the status of the fix, as I reported the wrong behaviour in december.
Thank you.
Last edited by MOISES on Fri Apr 10, 2020 4:06 pm, edited 1 time in total.
Saludos / Regards,
FWH 20.04, Harbour 3.2.0 dev (r1909261630) y BCC 7.40
FWH 20.04, Harbour 3.2.0 dev (r1909261630) y BCC 7.40
Re: xBrowse and SQLRDD bug
Up!
Saludos / Regards,
FWH 20.04, Harbour 3.2.0 dev (r1909261630) y BCC 7.40
FWH 20.04, Harbour 3.2.0 dev (r1909261630) y BCC 7.40
Re: xBrowse and SQLRDD bug
Up
Saludos / Regards,
FWH 20.04, Harbour 3.2.0 dev (r1909261630) y BCC 7.40
FWH 20.04, Harbour 3.2.0 dev (r1909261630) y BCC 7.40
Re: xBrowse and SQLRDD bug
???
Saludos / Regards,
FWH 20.04, Harbour 3.2.0 dev (r1909261630) y BCC 7.40
FWH 20.04, Harbour 3.2.0 dev (r1909261630) y BCC 7.40
Re: xBrowse and SQLRDD bug
Any update please?
Saludos / Regards,
FWH 20.04, Harbour 3.2.0 dev (r1909261630) y BCC 7.40
FWH 20.04, Harbour 3.2.0 dev (r1909261630) y BCC 7.40
- Antonio Linares
- Site Admin
- Posts: 37481
- Joined: Thu Oct 06, 2005 5:47 pm
- Location: Spain
- Contact:
Re: xBrowse and SQLRDD bug
Moises,
I just asked Rao, I am waiting for his answer
Also, please keep in mind that SQLRDD is a commercial product, that does not provide source code, and its not easy to support it in those circunstances,
anyhow we are doing out best to help you.
So, please, be patient. Changing the caption of your posts only provide a wrong sense to other users and its not a kind way to ask for help.
I just asked Rao, I am waiting for his answer
Also, please keep in mind that SQLRDD is a commercial product, that does not provide source code, and its not easy to support it in those circunstances,
anyhow we are doing out best to help you.
So, please, be patient. Changing the caption of your posts only provide a wrong sense to other users and its not a kind way to ask for help.
Re: xBrowse and SQLRDD bug
Hable con Marcelo Lombardo del Proyecto xHarbour.
Skype:
marcelolombardo
Saludos.
Skype:
marcelolombardo
Saludos.
João Santos - São Paulo - Brasil
Re: xBrowse and SQLRDD bug
Olá,
Como não falo nem português nem brasileiro, poderia partilhar connosco a sua resposta?
Muito obrigado.
Como não falo nem português nem brasileiro, poderia partilhar connosco a sua resposta?
Muito obrigado.
Saludos / Regards,
FWH 20.04, Harbour 3.2.0 dev (r1909261630) y BCC 7.40
FWH 20.04, Harbour 3.2.0 dev (r1909261630) y BCC 7.40
Re: xBrowse and SQLRDD bug
usted puede hablar en español con Marcelo Lombardo sin problemas, ó con Patrick Mast en ingléz. Saludos.
Mejor:
https://www.facebook.com/marcelombardo
https://www.facebook.com/patrickmast
https://www.facebook.com/luiz.guimaraes ... NMDOMiary0
Mejor:
https://www.facebook.com/marcelombardo
https://www.facebook.com/patrickmast
https://www.facebook.com/luiz.guimaraes ... NMDOMiary0
João Santos - São Paulo - Brasil
- nageswaragunupudi
- Posts: 8017
- Joined: Sun Nov 19, 2006 5:22 am
- Location: India
- Contact:
Re: xBrowse and SQLRDD bug
The issue is about vertical scrollbar support to xbrowse for SQLRDD.
I have sent modified xbrowse.prg, restoring previous functionality.
Vertical scrollbar support for SQLRDD is very limited.
In order to provide better support we need to know some details about SQLRDD.
We will start explaining with a DBFCDX DBF.
In this example, states.dbf is used via DBFCDX and index order is set to field NAME and also a filter is set:
In this case, xbrowse knows that the total number of visible records in the DBF are 9 (nine) with the help of the function OrdKeyCount().
Also xbrowse knows that the current record is 7th (seventh) from top using the function OrdKeyNo().
With this information, xbrowse is able to position the thumb of the scrollbar at 7/9 of the scrollbar.
Also if the user drags the scrollbar to say 3/9th position on the scrollbar, then xbrowse will move the record position to the 3rd record from the top using OrdKeyGoTo().
Using this example, please advise us how should xbrowse ascertain
1) The total number of records visible in the DBF
2) What is the serial number of the current record counting from the top.
3) How to go to a record at the nth position when counted from the top.
If you can provide us what functions to use to know the above three, then we will be able to provide full support for vertical scrollbar.
Please help us.
I have sent modified xbrowse.prg, restoring previous functionality.
Vertical scrollbar support for SQLRDD is very limited.
In order to provide better support we need to know some details about SQLRDD.
We will start explaining with a DBFCDX DBF.
In this example, states.dbf is used via DBFCDX and index order is set to field NAME and also a filter is set:
Code: Select all
function XbrVScroll
field NAME
local oDlg, oBrw, oFont
USE STATES NEW VIA "DBFCDX"
SET ORDER TO TAG NAME
SET FILTER TO NAME >= "A" .AND. NAME <= "D"
GO TOP
DEFINE FONT oFont NAME "TAHOMA" SIZE 0,-14
DEFINE DIALOG oDlg SIZE 400,300 PIXEL TRUEPIXEL FONT oFont TITLE "VSCROLLBAR"
@ 20,20 XBROWSE oBrw SIZE -20,-20 PIXEL OF oDlg ;
DATASOURCE "STATES" ;
COLUMNS "RECNO()", "CODE", "NAME" ;
PICTURES "999" ;
CELL LINES NOBORDER
WITH OBJECT oBrw
:CreateFromCode()
END
ACTIVATE DIALOG oDlg CENTERED
RELEASE FONT oFont
return nil
In this case, xbrowse knows that the total number of visible records in the DBF are 9 (nine) with the help of the function OrdKeyCount().
Also xbrowse knows that the current record is 7th (seventh) from top using the function OrdKeyNo().
With this information, xbrowse is able to position the thumb of the scrollbar at 7/9 of the scrollbar.
Also if the user drags the scrollbar to say 3/9th position on the scrollbar, then xbrowse will move the record position to the 3rd record from the top using OrdKeyGoTo().
Using this example, please advise us how should xbrowse ascertain
1) The total number of records visible in the DBF
2) What is the serial number of the current record counting from the top.
3) How to go to a record at the nth position when counted from the top.
If you can provide us what functions to use to know the above three, then we will be able to provide full support for vertical scrollbar.
Please help us.
Regards
G. N. Rao.
Hyderabad, India
G. N. Rao.
Hyderabad, India
Re: xBrowse and SQLRDD bug
Thank you very much for your time and support.
With the changes you have sent me, it is possible to navigate in the xBrowse by moving the vertical scroll bar. The only remaining problem is if I perform a DbGoBottom() and then call xBrowse, the vertical scroll bar still appears on top.
OrdKeyCount() works perfect under SQLRDD, but OrdKeyNo() is not supported, it returns 0 always. They are not going to fix it, they say it is impossible.
In the past, you solved I think as follows:
http://forums.fivetechsupport.com/viewt ... 98#p138698
With the changes you have sent me, it is possible to navigate in the xBrowse by moving the vertical scroll bar. The only remaining problem is if I perform a DbGoBottom() and then call xBrowse, the vertical scroll bar still appears on top.
OrdKeyCount() works perfect under SQLRDD, but OrdKeyNo() is not supported, it returns 0 always. They are not going to fix it, they say it is impossible.
In the past, you solved I think as follows:
Code: Select all
DEFAULT ::bKeyNo := ::bBookMark, ;
::bKeyCount := { || ( ::cAlias )->( LastRec() ) }
Saludos / Regards,
FWH 20.04, Harbour 3.2.0 dev (r1909261630) y BCC 7.40
FWH 20.04, Harbour 3.2.0 dev (r1909261630) y BCC 7.40
- nageswaragunupudi
- Posts: 8017
- Joined: Sun Nov 19, 2006 5:22 am
- Location: India
- Contact:
Re: xBrowse and SQLRDD bug
This code:
::bBookMark is { |x| If( x == nil, RECNO(), DBGOTO( x ) ) }
This works well if the DBF is in natural order (with no index set) and when no filter is set.
If the DBF is set to an index or if a filter is set, this behaves very erratically.
Do you want this?
Please also let me know do these functions work reliably with SQLRDD?
Can you also please confirm that when a filter is set, OrdKeyCount() returns the count of filtered records only?
In the post you referred, Mr. Kokoo suggested maintaining an array of RecNo()s outside the xbrowse. This works well but the programmer has to do an extra work of creating the array at the beginning and recreating whenever the index is changed, record is added or deleted of a keyvalue is edited and modified. This is upto you if you want to adopt this approach.
Code: Select all
DEFAULT ::bKeyNo := ::bBookMark, ;
This works well if the DBF is in natural order (with no index set) and when no filter is set.
If the DBF is set to an index or if a filter is set, this behaves very erratically.
Do you want this?
Please also let me know do these functions work reliably with SQLRDD?
Code: Select all
DBFILTER()
ORDSETFOCUS()
In the post you referred, Mr. Kokoo suggested maintaining an array of RecNo()s outside the xbrowse. This works well but the programmer has to do an extra work of creating the array at the beginning and recreating whenever the index is changed, record is added or deleted of a keyvalue is edited and modified. This is upto you if you want to adopt this approach.
Regards
G. N. Rao.
Hyderabad, India
G. N. Rao.
Hyderabad, India
- nageswaragunupudi
- Posts: 8017
- Joined: Sun Nov 19, 2006 5:22 am
- Location: India
- Contact:
Re: xBrowse and SQLRDD bug
To give the same effect as the code:
we made these changes:
We sent the modified xbrowse.prg to your email.
Please check.
Code: Select all
::bKeyNo := ::bBookMark
Code: Select all
DEFAULT ::bKeyNo := { |n| ( ::cAlias )->( SqlRddKey( n ) ) }
...
...
static function SqlRddKey( x )
if Empty( DBFILTER() ) .and. Empty( OrdSetFocus() )
if x != nil
DBGOTO( x )
endif
return RECNO()
endif
return 0
Please check.
Regards
G. N. Rao.
Hyderabad, India
G. N. Rao.
Hyderabad, India
Re: xBrowse and SQLRDD bug
Yes, I confirm that DBFILTER()/SET FILTER TO and ORDSETFOCUS() work under SQLRDD.
And yes, when a filter is set, OrdKeyCount() Works too.
But never OrdKeyNo()
I am going to test your new versión and share the results.
Thank you.
And yes, when a filter is set, OrdKeyCount() Works too.
But never OrdKeyNo()
I am going to test your new versión and share the results.
Thank you.
Saludos / Regards,
FWH 20.04, Harbour 3.2.0 dev (r1909261630) y BCC 7.40
FWH 20.04, Harbour 3.2.0 dev (r1909261630) y BCC 7.40
Re: xBrowse and SQLRDD bug
Up!
Saludos / Regards,
FWH 20.04, Harbour 3.2.0 dev (r1909261630) y BCC 7.40
FWH 20.04, Harbour 3.2.0 dev (r1909261630) y BCC 7.40