C# 在中心设置“更新进度”面板

C# 在中心设置“更新进度”面板,c#,asp.net,css,ajax,C#,Asp.net,Css,Ajax,我有一个关于更新进度面板的问题。 我想在我的屏幕中间安装更新进度面板! 有人能告诉我,这样做的想法是什么吗?系统处理时,“更新进度”面板会显示一些内容(一些文本、图像和标记) 因此,您需要使用添加的标记 例如,如果你有一个显示的div,你可以让它像这样位于中心 <div style="width:200px;margin:0 auto;">Processing...</div> 并将您的div更改为: <div class="posCentre">Proce

我有一个关于更新进度面板的问题。 我想在我的屏幕中间安装更新进度面板!
有人能告诉我,这样做的想法是什么吗?

系统处理时,“更新进度”面板会显示一些内容(一些文本、图像和标记)

因此,您需要使用添加的标记

例如,如果你有一个显示的div,你可以让它像这样位于中心

<div style="width:200px;margin:0 auto;">Processing...</div>
并将您的div更改为:

<div class="posCentre">Processing...</div>
处理。。。

您可以使用css来实现这一点

<style type="text/css" media="screen">
/* commented backslash hack for ie5mac \*/ 
html, body{height:100%;} 
/* end hack */
.CenterPB{
position: absolute;
left: 50%;
top: 50%;
margin-top: -30px; /* make this half your image/element height */
margin-left: -30px; /* make this half your image/element width */
}
</style>

/*对ie5mac\*/
html,正文{高度:100%;}
/*结束攻击*/
.CenterPB{
位置:绝对位置;
左:50%;
最高:50%;
页边距顶部:-30px;/*使此图像/元素高度减半*/
左边距:-30px;/*将这部分宽度设为图像/元素宽度的一半*/
}
在div中有进度条

<div class="CenterPB" style="height:60px;width:60px;" >Progress bar here</div>
此处的进度条
参考资料:


如果您使用jQuery,您也可以尝试(非常轻量级)。

@davMcLean:谢谢您的回复!!别担心,希望对你有帮助。
<style type="text/css" media="screen">
/* commented backslash hack for ie5mac \*/ 
html, body{height:100%;} 
/* end hack */
.CenterPB{
position: absolute;
left: 50%;
top: 50%;
margin-top: -30px; /* make this half your image/element height */
margin-left: -30px; /* make this half your image/element width */
}
</style>
<div class="CenterPB" style="height:60px;width:60px;" >Progress bar here</div>