如何将“编辑”按钮移动到“详细信息视图”顶部?
我有一个绑定到 SqlDataSource 的 DetailsView。它还有一个编辑命令字段,显示在自动生成的行的底部。
<asp:DetailsView ID="DetailsView1" runat="server"
ForeColor="#333333" GridLines="None" Height="50px" Width="150px"
DataSourceID="SqlDataSource2" Caption="System Parameters" CellSpacing="2">
<Fields>
<asp:CommandField ShowEditButton="True" />
</Fields>
</asp:DetailsView>
有超过 50 列,所以我不想手动添加绑定字段。
如何将“编辑”按钮移动到“详细信息视图”(第一行)的顶部?
谢谢,
I have a DetailsView which is bound to a SqlDataSource. It also has an Edit CommandField which appears on the bottom of the autogenerated rows.
<asp:DetailsView ID="DetailsView1" runat="server"
ForeColor="#333333" GridLines="None" Height="50px" Width="150px"
DataSourceID="SqlDataSource2" Caption="System Parameters" CellSpacing="2">
<Fields>
<asp:CommandField ShowEditButton="True" />
</Fields>
</asp:DetailsView>
There are over 50 columns so I wouldn't like to add the bound fields manually.
How would that be possible to move the Edit button on top of the DetailsView (first row)?
Thanks,
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
似乎有点不清楚,但一个可能的解决方案是给编辑按钮一个相对位置。然后使用顶部 (-) 或底部 (+) 功能将其移至顶部。
Seems a bit unclear, but a possible solution would be to give the edit button a relative position. Then move it to the top by using the top (-) or bottom (+) functions.