Lazarus
Home
Help
TinyPortal
Search
Login
Register
Lazarus
»
Forum
»
Programming
»
LCL
»
BeginUpdate, EndUpdate for TScrollBox
Free Pascal
Website
Downloads
Wiki
Documentation
Bugtracker
Mailing List
Lazarus
Website
Downloads (Laz+FPC)
Packages (OPM)
FAQ
Wiki
Documentation (RTL/FCL/LCL)
Bugtracker
CCR Bugs
GIT
Mailing List
Other languages
Foundation
Website
Useful Wiki Links
Project Roadmap
Getting the Source
Screenshots
How to use the forum
Forum Rules
About donations (wiki)
Bookstore
Computer Math and Games in Pascal
(preview)
Lazarus Handbook
Search
Advanced search
Recent
The best name for procedu...
by
J-G
[
Today
at 07:49:19 pm]
var vs out
by
Paolo
[
Today
at 06:37:35 pm]
Identify network devices
by
gidesa
[
Today
at 06:01:48 pm]
[UNSOLVED] Splitting an i...
by
madref
[
Today
at 05:40:09 pm]
Error installing EyeCandy...
by
madref
[
Today
at 05:21:41 pm]
Lazarus Bugfix Release 4....
by
geraldholdsworth
[
Today
at 04:55:42 pm]
[Solved[ How to define th...
by
Mike.Cornflake
[
Today
at 03:42:11 pm]
Dataset EnableControls/Di...
by
Mike.Cornflake
[
Today
at 03:37:42 pm]
'ReadStr' ?
by
J-G
[
Today
at 03:07:16 pm]
Debugging in a real termi...
by
Martin_fr
[
Today
at 02:59:09 pm]
how to bring in view the ...
by
Aruna
[
Today
at 02:33:55 pm]
Is it possible to communi...
by
dbannon
[
Today
at 02:15:44 pm]
TFPHTTPServer DDoS protec...
by
LemonParty
[
Today
at 12:54:23 pm]
enable easy marker moveme...
by
Paolo
[
Today
at 12:10:00 pm]
Unleashed Pascal (async/a...
by
creaothceann
[
Today
at 12:09:09 pm]
MOVED: soucis scrollbars ...
by
Martin_fr
[
Today
at 11:09:38 am]
soucis scrollbars V4.8 ?
by
Martin_fr
[
Today
at 11:08:13 am]
Star Wars Galaxian
by
PierceNg
[
Today
at 10:37:08 am]
[closed] Is case for stri...
by
egsuh
[
Today
at 10:27:17 am]
Automatic generation of *...
by
dbannon
[
Today
at 09:00:50 am]
Gtk3 becomes default widg...
by
dbannon
[
Today
at 08:44:10 am]
TurboBird for FireBird 5
by
laguna
[
Today
at 07:45:04 am]
Bugs caused by the weathe...
by
dsiders
[
Today
at 04:40:59 am]
Lazarus Bugfix Release 4....
by
moinsen
[
Today
at 12:57:37 am]
Lazarus IDE plugin that i...
by
BSaidus
[August 10, 2026, 11:21:20 pm]
« previous
next »
Print
Pages: [
1
]
Author
Topic: BeginUpdate, EndUpdate for TScrollBox (Read 2297 times)
LemonParty
Hero Member
Posts: 606
BeginUpdate, EndUpdate for TScrollBox
«
on:
August 15, 2025, 07:03:43 pm »
Hello.
I have a scroll box and I change positions of many contained controls. At first time this become laggy. Is there BeginUpdate, EndUpdate for scroll box?
Logged
Lazarus v. 4.99. FPC v. 3.3.1. Windows 11
Thaddy
Hero Member
Posts: 19606
Glad to be alive.
Re: BeginUpdate, EndUpdate for TScrollBox
«
Reply #1 on:
August 15, 2025, 07:11:09 pm »
use begin/endupdate from the parent control that contains all controls that change.
Logged
Any "programmer" that knows only one programming language is not a programmer
LemonParty
Hero Member
Posts: 606
Re: BeginUpdate, EndUpdate for TScrollBox
«
Reply #2 on:
August 15, 2025, 07:29:09 pm »
My parent control is the scroll box. And scroll box have no methods Begin/EndUpdate.
Logged
Lazarus v. 4.99. FPC v. 3.3.1. Windows 11
marcov
Administrator
Hero Member
Posts: 12982
FPC developer.
Re: BeginUpdate, EndUpdate for TScrollBox
«
Reply #3 on:
August 15, 2025, 11:05:05 pm »
Yes. Delphi also has this problem, so I assume it is a win32 issue. I have a few helpers for that like
Code: Pascal
[Select]
[+]
[-]
procedure
Scrollbarseteventlessposition
(
scr
:
TScrollbar
;
def
:
integer
)
;
var
oldevent
:
TNotifyEvent
;
begin
oldevent
:
=
scr
.
OnChange
;
scr
.
onchange
:
=
nil
;
scr
.
Position
:
=
def
;
scr
.
OnChange
:
=
oldevent
;
end
;
procedure
Scrollbarseteventlesspositionminmax
(
scr
:
TScrollbar
;
def
,
min
,
max
:
integer
)
;
var
oldevent
:
TNotifyEvent
;
begin
oldevent
:
=
scr
.
OnChange
;
scr
.
onchange
:
=
nil
;
scr
.
SetParams
(
def
,
min
,
max
)
;
scr
.
OnChange
:
=
oldevent
;
end
;
Logged
LemonParty
Hero Member
Posts: 606
Re: BeginUpdate, EndUpdate for TScrollBox
«
Reply #4 on:
August 15, 2025, 11:20:46 pm »
I found that when set the scroll box property
Visible
to False, then do changes and then set to True lags not occur.
Logged
Lazarus v. 4.99. FPC v. 3.3.1. Windows 11
jamie
Hero Member
Posts: 7891
Re: BeginUpdate, EndUpdate for TScrollBox
«
Reply #5 on:
August 16, 2025, 08:01:13 pm »
There is a BeginFormUpdate and EndFormUpdate that may work for you.
Logged
The only true wisdom is knowing you know nothing
LemonParty
Hero Member
Posts: 606
Re: BeginUpdate, EndUpdate for TScrollBox
«
Reply #6 on:
August 17, 2025, 02:39:28 pm »
Quote from: jamie on August 16, 2025, 08:01:13 pm
There is a BeginFormUpdate and EndFormUpdate that may work for you.
This works too. Thank you.
Logged
Lazarus v. 4.99. FPC v. 3.3.1. Windows 11
Print
Pages: [
1
]
« previous
next »
Lazarus
»
Forum
»
Programming
»
LCL
»
BeginUpdate, EndUpdate for TScrollBox
TinyPortal
© 2005-2018