Upvote 1

Scroll content so when it reaches the template at the top, the content goes behind the template?

In Progress Ikibkilam 5 years ago

I would like to be able to scroll content, such that when it reaches the template at the top (the template is a simple rectangle widget), then content should go behind the template and not remain visible. At present, it scrolls just fine, but remains visible on top of the template.

Please note, I am not using Dynamic Panels, so this is just a screen scroll. I tried selecting 'Always on Top' for the template, but that did not help.

Thank you for your assistance.

Ikib

Replies (1)
photo
1

Select the Rectangle and look to the Properties palette. Then click the 'Display pin position' options box, and change the 'Y' parameter to 'Pin to top'.

photo
1

Thank you, Danielle.

That is exactly what I already have. The Rectangle's Position Properties are as follows: X: Pin to center, Y: Pin to top. My text on the top 'Sign up' is also pinned to the top, and so is the back button.

So, something else is required. What else should I be doing, to get the scrolled content to scroll behind the rectangle.

Thank you for your assistance.

photo
1

Thanks for clarifying. In that case, you could create an "On Scroll" + Hide" event, hiding the Rectangle. Then, create a Condition for this event that is When... Windows Scroll Y < 50 (or whatever number the scroll is when you would like to hide the Rectangle). Then, in the Events palette, click the 'Else' text and create an "On Scroll" + "Show" event, showing the Rectangle. There's no need to create a condition for this event. Does that accomplish what you're looking for?

photo
3

Thank you Danielle.

I made your suggestion work. Thank you.

However, I find this approach to be very tedious, especially when I have put an On Scroll Hide/Show event on multiple (in my case 10) widgets. Each such event requires me to compute the pixels for every widget, and if I ever make a change to the page, then I have to redo everything.

Why is it that I cannot simply set a property on the template at the top (behind which my scrolled content is to disappear), that stipulates that the template is to always remain on the top, during a scroll?

Thank you again for your help with getting this to work. Though, I would like to understand why there isn't a simpler solution.

photo
Leave a Comment
 
Attach a file
You can't vote. Please authorize!
You can't vote. Please authorize!
You can't vote. Please authorize!
You can't vote. Please authorize!
You can't vote. Please authorize!
You can't vote. Please authorize!
You can't vote. Please authorize!