TWBrowse vertical scrollbar always

Post Reply
User avatar
Enrico Maria Giordano
Posts: 7355
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia
Contact:

TWBrowse vertical scrollbar always

Post by Enrico Maria Giordano »

Is there an easy way to set the TWBrowse vertical scrollbar always showing even if there are no rows or one row only?

EMG
User avatar
James Bott
Posts: 4654
Joined: Fri Nov 18, 2005 4:52 pm
Location: San Diego, California, USA
Contact:

Post by James Bott »

Enrico,

This is from an old message. I don't know if it works.
When a zero value range is set on a scrollbar, it becomes invisible,
so you may modify your bLogicLen codeblock to return one, when
it is zero:

Code: Select all

   <oBrw>:bLogicLen = { || If( NumberOfRecords == 0, 1, ... ) }
Regards,
James
User avatar
Roger Seiler
Posts: 223
Joined: Thu Dec 01, 2005 3:34 pm
Location: Nyack, New York, USA
Contact:

Post by Roger Seiler »

Enrico,

I don't know if this will help, because it has to do with listbox instead of Wbrowse.

When designing a listbox in Borland Resource Workshop, in the properties dialog if you specify "scroll bar always" and then look at the code that RW generates, it inserts LBS_DISABLENOSCROLL in the code for the listbox. Maybe if you can discover how this works you may be able to apply the same concept to Wbrowse.

Good luck!

- Roger
User avatar
Roger Seiler
Posts: 223
Joined: Thu Dec 01, 2005 3:34 pm
Location: Nyack, New York, USA
Contact:

Post by Roger Seiler »

Enrico,

Here is another clue...

In scroll.c of fwh\source\winapi there is SIF_DISABLENOSCROLL

Maybe you can figure out how to use that.

- Roger
ask
Posts: 99
Joined: Wed Nov 02, 2005 10:40 am

Re: TWBrowse vertical scrollbar always

Post by ask »

EnricoMaria wrote:Is there an easy way to set the TWBrowse vertical scrollbar always showing even if there are no rows or one row only?

EMG
I would use <BrowseObject>:nstyle:=nOr( WS_CHILD, WS_HSCROLL,;
WS_BORDER, WS_VISIBLE, WS_TABSTOP)

regards
A.S.K
Post Reply