📄 showvote.aspx
字号:
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="ShowVote.aspx.cs" Inherits="ShowVote" %>
<html xmlns="http://www.w3.org/1999/xhtml" >
<head id="Head1" runat="server">
<title>漂亮的企业网站</title>
<meta name="GENERATOR" Content="Microsoft Visual Studio .NET 7.1">
<meta name="CODE_LANGUAGE" Content="C#">
<meta name="vs_defaultClientScript" content="JavaScript">
<meta name="vs_targetSchema" content="http://schemas.microsoft.com/intellisense/ie5">
<link href="CSS/ASPNET2BaseCss.css" type="text/css" rel="stylesheet">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"><style type="text/css">
<!--
body,td,th {
font-family: 宋体;
font-size: 12px;
color: #000000;
}
a {
font-size: 12px;
color: #000000;
}
a:visited {
color: #000000;
}
body {
background-color: #11C4FF;
margin-left: 0px;
margin-top: 0px;
margin-right: 0px;
margin-bottom: 0px;
}
-->
</style></HEAD>
<body>
<form id="Form1" method="post" runat="server">
<table width="100%" height="100" border="0" cellPadding="0"
cellSpacing="0" borderColor="#93bee2" class="GbText" style="BORDER-COLLAPSE: collapse">
<tr><td align="center"><asp:DataGrid ID="VoteList" Runat="server" CssClass="GbText" BorderColor="#CC9966" AutoGenerateColumns="False" DataKeyField="VoteID" CellPadding="0">
<HeaderStyle BackColor="Orange" width="600px"></HeaderStyle>
<Columns>
<asp:TemplateColumn HeaderText="投票项目">
<ItemStyle Width="200px" BorderWidth="1px"></ItemStyle>
<ItemTemplate>
<%# DataBinder.Eval(Container.DataItem,"VoteItem")%>
</ItemTemplate>
</asp:TemplateColumn>
<asp:TemplateColumn HeaderText="所占总票的百分比">
<ItemStyle Width="300px" BorderWidth="1px" HorizontalAlign="Left"></ItemStyle>
<ItemTemplate>
<asp:Image ID="voteImage" Runat="server" Height="20" Width='<%# FormatVoteImage(FormatVoteCount(DataBinder.Eval(Container.DataItem,"VoteCount").ToString()))%>' ImageUrl="Images/vote.gif">
</asp:Image>
<%# FormatVoteCount(DataBinder.Eval(Container.DataItem,"VoteCount").ToString())%>
%
</ItemTemplate>
</asp:TemplateColumn>
<asp:TemplateColumn HeaderText="票数">
<ItemStyle Width="100px" BorderWidth="1px"></ItemStyle>
<ItemTemplate>
<asp:Label ID="VoteCount" Runat="server">
<%# DataBinder.Eval(Container.DataItem,"VoteCount")%>
</asp:Label>
</ItemTemplate>
</asp:TemplateColumn>
</Columns>
</asp:DataGrid></td>
</tr>
<tr>
<td width="100%" height="14" align="center" bgcolor="#FFFFFF"><asp:Label ID="VoteMessage" Runat="server" ForeColor="Red" Width="100%"></asp:Label></td>
</tr>
<tr>
<td width="100%" height="23" align="center"> </td>
</tr>
</table>
</form>
</body>
</HTML>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -