How To Make TSynMemo Scroll Under Program Control lazarus / 31-LCL ---------------------------------------------------------------------- MrBill · 2012-12-20 17:15 Hi Experts, I have a TSynMemo which contains about 100 lines.  I would like, under program control, to scroll the displayed lines up or down so a specific line is in the middle of the TSynMemo display area.  I don't see a way to do this. Any suggestions or hints? Thanks, Bill ---------------------------------------------------------------------- Blaazen · 2012-12-20 17:30 Code: [Select]SynMemo1.CaretY:=50; ---------------------------------------------------------------------- Martin_fr · 2012-12-20 18:18 You can set SynEdit.TopLine you also have SynEdit.LinesInWindow (full lines, excluding the partially visible at the bottom. If you use folding, there is more, but for unfolded, that should be enough. ---------------------------------------------------------------------- MrBill · 2012-12-24 15:36 Thanks for the pointers. By the way, I stumbled upon another way to do it:  If one sets the cursor location to a location which is not in the displayed lines (using SelStart), then the control will automatically scroll the so the line containing the SelStart position will be in the display window. Thanks again, Bill