📄 newtempcourse.aspx
字号:
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="NewTempCourse.aspx.cs" Inherits="SystemManage_NewTempCourse" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title>新增临时课</title>
<base target=_self />
<script type="text/javascript">
function showColorPicker(txtColor)
{
var dialogObject = new Object() ;
dialogObject.colorValue = txtColor.value ;
dialogObject.valueObject = txtColor ;
dialogObject.styleObject = null ;
var colorValue = window.showModalDialog("../htc/2k3ColorPicker/2k3ColorPickerDialog.htm", dialogObject, "dialogWidth:373px; dialogHeight:460px; center:yes; help:no; resizable:no; status:no") ;
txtColor.value = (colorValue == false) ? txtColor.value : colorValue ;
}
function textChange(button)
{
alert(button.backgroundColor);test.style.backgroundColor
}
function hidediv()
{
window.close();
}
function verifyName(Name)
{
PageMethods.VerifyUser(Name,onVerifyCompleted);
}
function onVerifyCompleted(passed)
{
if(passed)
{
lblMsg.innerText='存在同名';
TextBox1.value="";
TextBox1.focus();
TextBox1.select();
return false;
}
else
{
lblMsg.innerText='';
}
}
</script>
</head>
<body class="model">
<form id="form1" runat="server">
<div>
<asp:ScriptManager ID="ScriptManager1" runat="server" EnablePageMethods="True">
</asp:ScriptManager>
<br />
<table align="center">
<tr>
<td align="right">
<asp:Label ID="Label1" runat="server" Text="课程名称" Font-Size="9pt"></asp:Label></td>
<td >
<asp:TextBox ID="TextBox1" runat="server" Width="111px" Font-Size="9pt" onchange="verifyName(this.value)"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="TextBox1"
Display="Dynamic" ErrorMessage="课程名不能为空" Font-Size="9pt"></asp:RequiredFieldValidator>
</td>
</tr>
<tr>
<td align="right">
<asp:Label ID="Label2" runat="server" Text="显示颜色" Font-Size="9pt"></asp:Label></td>
<td >
<asp:TextBox ID="txtColor" runat="server" Width="83px" Font-Size="9pt"></asp:TextBox>
<input onclick="showColorPicker(this.parentElement.firstChild)" style="border-right: gray 1px solid;
border-top: gray 1px solid; border-left: gray 1px solid; width: 25px; border-bottom: gray 1px solid;
height: 20px" title="单击更改显示颜色" type="button" />
<asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="txtColor"
Display="Dynamic" ErrorMessage="显示颜色" Font-Size="9pt"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td align="left" colspan="2">
<asp:Button ID="Button1" runat="server" OnClick="Button1_Click" Text="确定" />
<input id="Button2" type="button" value="取消" onclick="hidediv()" />
</td>
</tr>
</table>
</div>
<p align=center><asp:Label ID="lblMsg" runat="server" ForeColor="Red"></asp:Label></p>
</form>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -