Chat 9 Rich控件概要1.pptVIP

  • 15
  • 0
  • 约6.05千字
  • 约 21页
  • 2017-07-02 发布于湖北
  • 举报
Chat 9 Rich控件概要1

(4)将用户控件添加至Default.aspx页中,并在Default.aspx页的【登录】按钮的Click事件下添加如下代码,获取用户控件的文本框值,并判断用户输入是否合法。其代码如下所示: protected void Button1_Click(object sender, EventArgs e) { if (WebUserControl31.str_UserName == || WebUserControl31.str_Password == ) { Response.Write(scriptalert(用户名或密码不能为空!)/script);? } else { if (WebUserControl31.str_UserName == dqpi WebUserControl31.str_Password == 123456) { Response.Write(scriptalert(您是合法用户,欢迎光临!)/script); } else { Response.Write(scriptalert(用户名或密码错误!)/script); } } } The Last Word This chapter introduced you to web controls and their object interface. * * * * * * * * 说明: 1)每个广告必须用Ad和/Ad标记括起来; 2)每个广告的图片要一样大,以保持板位的整体效果; 3)排序文件用advertisements和/advertisements标记括起来; 4)保存文件时一定以“.xml”为扩展名,还要存为“Unicode”编码类型,否则将发生读取错误; 2、KeyWordFilter属性:根据指定的关键字筛选广告,即:只为AdRotator控件选择包含该关键字的公布。 3、Target属性:指示广告要打开的目标窗口。 4、OnAdCreated事件:当在页面上创建AdRotator控件时触发该事件。 * * * * * * * * * * * Chapter 9 Rich Controls Chapter 9 Rich Controls Chapter 9 Rich Controls Chapter 9 Rich Controls Chapter 9 Rich Controls Chapter 9 Rich Controls Chapter 9 Rich Controls Chapter 9 Rich Controls 主讲教师:吴秀芹 电子邮件:wxqltl@163.com 电 话:6507725 办公室地址:一教D座313室 OUTLINE Calendar 控件 AdRotator 控件 用户控件 Calendar控件用来在Web页面中显示日历中的可选日期,并显示与特定日期关联的数据。 属 性 说 明 Caption 设置呈现日历标题的文本值 FirstDayOfWeek 设置将在日历的第一列中显示的一周中的某一天 NextMonthText 设置为下一月导航控件显示的文本 PrevMonthText 设置为前一月导航控件显示的文本 SelectedDate 设置当前选定的日期 SelectionMode 设置Calendar对象的选择模式 ShowDayHeader 确定控件是否在日历标头中显示一周中每一天的名称 ShowNextPrevMonth Calendar控件是否在标题部分显示下个月和上个月导航元素 Calendar控件外观的设置: 使用“自动套用格式”对话框选择外观格式。 设置属性。 设置扩展样式属性。 自定义个别日期呈现。 CALENDAR控件应用举例 protected void Calendar1_SelectionChanged(object sender, EventArgs e) { Label1.Text = 今天是: + Calendar1.TodaysDate.ToShortDateString(); Label1.Text += /br + 您选择的日期是: + Calendar1.SelectedDa

文档评论(0)

1亿VIP精品文档

相关文档