xBrowse ( follow up )

xBrowse ( follow up )

Postby Rick Lipkin » Fri Mar 20, 2009 7:55 pm

Just a quick question .. when xBrowse opens and goes to the first record .. why is the very top left cell always hi-lited in black .. if you click on it it will turn the correct color .. I do have on init oBrw:SetFocus() .. but that does not seem to effect the initial first cell as xbrow opens ..

Any thoughts as how to move the cursor to the first cell so the listbox becomes active ?

Thanks
Rick Lipkin
User avatar
Rick Lipkin
 
Posts: 2665
Joined: Fri Oct 07, 2005 1:50 pm
Location: Columbia, South Carolina USA

Re: xBrowse ( follow up )

Postby ukoenig » Fri Mar 20, 2009 9:53 pm

Hello Rick,

There are two color-settings

// xBrowse got Focus Color Row/Cell - Text and Background
// ---------------------------------------------------------------------
oLbx:bClrSelFocus = { || { SEL_TEXTCOLOR, SEL_BACKCOLOR } }
// Black Text on White Background
oLbx:bClrSelFocus = { || { 0, 16777215 } }

// xBrowse Lost Focus Color Text and Background
// ---------------------------------------------------------
oLbx:bClrSel = { || { LOST_TCOLOR, LOST_BCOLOR } }
// Black Text on White Background
oLbx:bClrSel = { || { 0, 16777215 } }

Regards
Uwe :lol:
Last edited by ukoenig on Sat Mar 21, 2009 6:35 pm, edited 1 time in total.
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany

Re: xBrowse ( follow up )

Postby nageswaragunupudi » Sat Mar 21, 2009 5:25 pm

This is a problem only when browse is in a dialog and browse is not the first control defined. "ON INIT oBrw:SetFocus()" does not help. Whatever we do ( as far as I know ), the first control defined gets focus when the dialog is activated.

In such cases, ( till I learn a better way ) I define the browse as the first control and then define all other controls ( even those which appear above the browse ). Alternatively I remove WS_TABSTOP from the controls defined prior to browse.

If I create the dialog from resources, either I change the taborder or remove WS_TABSTOP style from the earlier controls.

I am also interested in knowing if there is a better way.
Regards

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

Re: xBrowse ( follow up )

Postby Daniel Garcia-Gil » Sat Mar 21, 2009 6:52 pm

Rick Lipkin

please try with

ON INIT( oBrw:SetFocus(), .F. )
User avatar
Daniel Garcia-Gil
 
Posts: 2365
Joined: Wed Nov 02, 2005 11:46 pm
Location: Isla de Margarita

Re: xBrowse ( follow up )

Postby nageswaragunupudi » Sat Mar 21, 2009 7:02 pm

Excellant
Thanks Mr Daniel.

Now I recollect that it was long time back solved in these forums too.
Regret I forgot
Regards

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

Re: xBrowse ( follow up )

Postby Rick Lipkin » Sat Mar 21, 2009 8:21 pm

Daniel

YES .. ON INIT( oBrw:SetFocus(), .F. ) worked perfectically !!!!

Many thanks
Rick Lipkin
User avatar
Rick Lipkin
 
Posts: 2665
Joined: Fri Oct 07, 2005 1:50 pm
Location: Columbia, South Carolina USA


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot] and 83 guests