Panel: is it a container for other views?

Beja

Expert
Licensed User
Longtime User
this question was first posted as reply in another thread, but I thought it
discusses a different issue so I opened a new thread for it.

Is Panel view a container of other views? I want to put for example, different
views on two panels in the same layout. how can I do that?
thanks for your help in advance.
Note: I tried it and found the views don't follow the panel on which they were
drown. (you move the panel they stay).
 

barx

Well-Known Member
Licensed User
Longtime User
Yes, that is it's main function. If you are creating the layout in the designer then you need to set the views' Parent property to the panel you wish to hold them.
 
Upvote 0

Penko

Active Member
Licensed User
Longtime User
I panel can be called a container for other views but I don't think this is fully cleared definition.

Panels are suitable to combine several views to a area(panel). The best part with panels is that they are also capable of loading layouts similar to activities. Views are added relatively to the panel. There are plenty of different applications.

I suggest that you read the beginners manual which gives more information where to start. You can find it in the downloads area.

Sent from my HTC Desire using Tapatalk 2
 
Upvote 0

klaus

Expert
Licensed User
Longtime User
When you want to add a view to a Panel in the Designer you must first select this panel and then add the view. Otherwise it will be added to the Activity.
You can change the views parent view in the Designer by selecting the correct one in the Parent property.

Best regards.
 
Upvote 0

Beja

Expert
Licensed User
Longtime User
Dears barx, Penko and Klaus
Thank you so much for the great and timely help!

Klaus, that's much easier to throw the panel first and then the view.. thanks for the tip!
It was also helpful to know that you can do the same by changing the view's parent.. but this one may involve DNA testing (really), to determine the digital parent.
 
Upvote 0
Top