当扩展器折叠时如何访问扩展器下的对象?
嗨,大家好 我有这样的代码,
<RichTextBox />
<Expander Header="expand">
<Grid>
<Rectangle />
</Grid>
</Expander>
虽然我已经折叠了扩展器,但我仍然无法访问richtextbox,因为richtextbox位于扩展器层下。 当扩展器折叠时我如何访问richtextbox?
hi guys
i have a code like this
<RichTextBox />
<Expander Header="expand">
<Grid>
<Rectangle />
</Grid>
</Expander>
although i already collapse the expander, i still cant access richtextbox, because richtextbox under layer of expander.
how i can access richtextbox when expander is collapse?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
如果您将对象放置在网格的同一行和同一列中,它们将会重叠。这两个对象都位于网格的第 0 行和第 0 列中。
我不确定你想实现什么目标。如果您不希望对象重叠,请使用
DockPanel
或StackPanel
来放置它们,或者如果您要使用网格,请将它们放在不同的位置行,例如:If you're laying out objects in the same row and column of a grid, they're going to overlap. Both of those objects are in row 0 and column 0 of the grid.
I'm not sure what you're trying to accomplish. If you don't want the objects to overlap, use a
DockPanel
orStackPanel
to lay them out, or if you're going to use a grid, put them in different rows, e.g.: