Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
1
Question by Lanbo · Feb 05, 2015 at 06:20 PM · uiscrollview

Simple Vertical List of UI Elements

I'm on this for two days now. I believed such a simple thing could be easily done or at least well documented, but I fail to find code or examples for it. Kind of getting desperate.

What I want: A scrollable list of elements that I can append to at runtime via code. So I found the docs about the Scroll Rect and the video for it. But it did not help me one bit, because it left out right the points I need.

So, as a child of the ScrollRect, I set an empty GameObject ("Content") with a Scroll Rect component. To that Content I append all the child UI Elements.

All I want is the following: All the children shall have the width of the Scroll View, but keep their height. And once the Elements grow out of the Content element, it shall resize and be scrollable.

So why is that so difficult to achieve? If anyone knows an example for this, I'll be most greatful.

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

1 Reply

· Add your reply
  • Sort: 
avatar image
3
Best Answer

Answer by Mmmpies · Feb 05, 2015 at 06:24 PM

It's not difficult, you just have to know how. Fortunately we walk in the footsteps of giants and @BoredMormon worked this out a while ago.

scrollable-panel

I wrote it down for someone on a slow connection but links to the tutorial are in there if you want to watch the clip instead of work through the pdf.


how-to-make-a-scrollable-panel-using-the-46-unity.pdf (515.6 kB)
Comment
Add comment · Show 4 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Lanbo · Feb 05, 2015 at 07:06 PM 0
Share

Thanks a lot for this, it worked perfectly. And thanks a thousand times for writing the PDF, I have great trouble with video tutorials.

avatar image Mmmpies · Feb 05, 2015 at 07:50 PM 0
Share

No problem @Lanbo, glad it helped.

avatar image darrelltstevens · Nov 15, 2020 at 07:41 AM 0
Share

dead links in answer

avatar image thefallengamesstudio darrelltstevens · Nov 15, 2020 at 05:41 PM 1
Share

Here's a tutorial I've made. Hope it helps

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

5 People are following this question.

avatar image avatar image avatar image avatar image avatar image

Related Questions

Scrollview with dynamic header (disappear when scroll up and appear when scroll down... smoothly) 0 Answers

uGUI ScrollRect too slow? 1 Answer

The Unity Scrollbar Handle NaN problem 0 Answers

ScrollRect contents do not align to top until input received 0 Answers

Recreating iPhone Home Screen in Unity 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges