Page 1 of 1

XBROWSE Questions

Posted: Thu Nov 07, 2019 10:49 am
by byte-one
1.)
I have 2 xbrowses with identical number of rows . The first xbrowse have a vert-scroll , the second are not. Now i will synchronize the actual row in the second browse by moving of the first browse.
Currently in the first xbrowse i have:

Code: Select all

….ON CHANGE oBrw2:nArrayAt := oBrw1:nArrayAt,oBrw2:refresh();
It is functioning, but the visible rows are different.

2.)
If i will paint nColdivider in a col with another color, this color are not in all cases are painted correct with the color from this col when i change the lines!

Code: Select all

oBrw:nColDividerStyle := LINESTYLE_BLACK
oBrw:aCols[i]:nColDividerStyle := LINESTYLE_BLACK
oBrw:aCols[i]:nColDividerColor := CLR_WHITE

Re: XBROWSE Questions

Posted: Thu Nov 07, 2019 12:49 pm
by ukoenig
Günther,
1.)
I have 2 xbrowses with identical number of rows . The first xbrowse have a vert-scroll , the second are not. Now i will synchronize the actual row in the second browse by moving of the first browse.
I needed the same solution for a language-translation

browser 1

:lColChangeNotify := .t.
:bChange := { || If( oBrw1:lFocused, SyncBrowses( oBrw1, oBrw2 ), nil ) }
:bGotFocus := { || SyncBrowses( oBrw1, oBrw2 ) }

browser 2

:lColChangeNotify := .t.
:bChange := { || If( oBrw2:lFocused, SyncBrowses( oBrw2, oBrw1 ), nil ) }
:bGotFocus := { || SyncBrowses( oBrw2, oBrw1 ) }

//------------

FUNCTION SYNCBROWSES( oBrw1, oBrw2 )

WITH OBJECT oBrw2
:BookMark := oBrw1:BookMark
:nRowSel := oBrw1:nRowSel
:Refresh()
END

RETURN NIL

regards
Uwe :D

Re: XBROWSE Questions

Posted: Thu Nov 07, 2019 1:47 pm
by nageswaragunupudi
I remember to have posted a sample for synchronized browses a long time back in this forum. Using Mr. Uwe's tool we may find it I guess.

Re: XBROWSE Questions

Posted: Thu Nov 07, 2019 2:47 pm
by ukoenig