Page 1 of 1

How to switch off VScroll?

Posted: Sat Nov 15, 2008 10:06 pm
by Otto
lVScroll is not workting.
Regards,
Otto

Posted: Sat Nov 15, 2008 11:29 pm
by Antonio Linares
Otto,

Could you please post a PRG example of what you are doing ? thanks

Posted: Sun Nov 16, 2008 8:25 am
by Otto
Hello Antonio,

I am sorry I forgot to mention the class:
It is TPanel. oVScroll seems to me as hardcoded.

Best regards,
Otto

Code: Select all

METHOD New( nTop, nLeft, nBottom, nRight, oWnd, lPixel, nClrText, nClrBack ) CLASS TPanel
…

   if ! Empty( ::oWnd:hWnd )
      ::Create()
      ::oWnd:AddControl( Self )
      DEFINE SCROLLBAR ::oVScroll VERTICAL OF Self
      ::oVScroll:SetRange( 0, 100 )
   else
      ::oWnd:DefControl( Self )
   endif

return Self

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

Posted: Sun Nov 16, 2008 9:48 am
by Antonio Linares
Otto,

You can always turn it off doing:

oPanel:oVScroll:SetRange( 0, 0 )

Please review fwppc\samples\TestPane.prg to see the concept.

Posted: Sun Nov 16, 2008 7:08 pm
by Otto
Antonio, thank you. It is working.
Best regards,
Otto