Page 1 of 1

wxGrid::SetScrollLineX doesn't work.

Posted: Fri May 15, 2009 5:54 pm
by kea_
Hello together,

I don't know what I'm doing wrong.
I use a wxGrid component and like to scroll automatically with the SetScrollLineX but the function doesn't work. Do I have to set before something? Or do I have to use the wxScrolledWindow::Scroll(x, y) function but I think then I have to override the event for scrolling to get the actual position.

Thank you for your answer.

Greeting kea_

Posted: Fri May 15, 2009 9:38 pm
by JimFairway
Hi kea_,

wxGrid::SetScrollLineX only sets how many pixels to move in the X direction when the user clicks in the scroll bar (not grabbing the thumb and moving it).

If you want to scroll to a specific cell, try wxGrid::MakeCellVisible - see http://docs.wxwidgets.org/2.6/wx_wxgrid ... ellvisible

Hope that helps,

Jim

Posted: Sat May 16, 2009 8:15 am
by kea_
hello,
thank for your answer.
It doesn't work but it doesn't matter I'm doing it in a other way (for me a better way).

Greeting kea_