我如何在后面的代码中获得控件的显示位置? [英] how do i get the display postion of a control at code behind?

查看:54
本文介绍了我如何在后面的代码中获得控件的显示位置?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在后面的代码中获得控件的显示位置?

我有一个按钮,该按钮显示在一个地方.如果我想知道按钮显示位置,那我该怎么办呢?我没有设置按钮位置,但是在此按钮的显示位置上,我想设置另一个控件位置,那么如何获取/设置按钮位置?

我想从代码后面做所有事情.

How do I get the display postion of a control in code behind?

I have a button, which display at a place. If I wanted to know the button display postion then how can I get this? I did not set button postion, but on display postion of this button I wanted to set my another control postion so how can I get/set the postion of button?

I wanted to do everything from code behind.

推荐答案

尝试一下,您会明白的.
Try this, u will understand..

<table style="width:100%;font-size:10pt;" class="DataTable" id="tbBtn" runat="server" visible="false">
               <tr>
                     <td colspan="2" style="text-align:center">
                                        <asp:Button ID="btnAccept" runat="server" CssClass="Button" OnClick="btnAccept_Click" Text="Accept" Width="60px" />
</td> 
  </tr>
</table>


这篇关于我如何在后面的代码中获得控件的显示位置?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆