OpenDCL Forums

OpenDCL => Runtime/AutoLISP => Topic started by: Peter2 on February 07, 2017, 01:44:35 AM

Title: Scroll a grid to last line?
Post by: Peter2 on February 07, 2017, 01:44:35 AM
I have a Grid where I want to scroll / to jump to the last line via Lisp. I tried
Code (autolisp) Select
(dcl-Grid-SetCurCell project/main_dlg/grd_daten (dcl-Grid-GetRowCount project/main_dlg/grd_daten))
but nothing happened.
What to do?
Title: Re: Scroll a grid to last line?
Post by: marcoheuer on February 07, 2017, 03:52:56 AM
hello peter,
try this:
Code (autolisp) Select
(dcl-Grid-SetCurCell project/main_dlg/grd_daten (1- (dcl-Grid-GetRowCount project/main_dlg/grd_daten)))

best regards
marco
Title: Re: Scroll a grid to last line?
Post by: Peter2 on February 07, 2017, 05:49:23 AM
Thanks Marco

I missed the 0-based counting of the rows .. :-[