Jump to content

Alternative to VertScrollBar.Position := 0


MarcoC

Recommended Posts

Hi all.

I have a vertical TUniScrollBox where I insert, runtime, a number of unipanels.
Panels are used to show to the users the results of some searches and, at the end of each search, I would like the scrollbox to go back to initial zero position (with first, top, panel shown to the user).
If I use the trick to change some panels height to zero (to hide those panel from user eyes without completely deleting them at that moment) a call to MyScrollBox.VertScrollBar.Position := 0, after the scrollbox is filled by panels (some zero height, some normal height), ends with an AV.
I know it's a dirt trick 😆 but I would like to use it if possible, so I wonder if there is something different that I can try to reset the vertical position of my scrollbox without getting an AV.
Thanks!
Marco

(Latest build of Unigui)

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...