⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 scorecontrol.cs

📁 动易SiteFactory&#8482 网上商店系统1.0源代码
💻 CS
字号:
namespace PowerEasy.WebSite.Controls
{
    using PowerEasy.Common;
    using PowerEasy.Web.UI;
    using System;
    using System.Web.UI.HtmlControls;
    using System.Web.UI.WebControls;

    public class ScoreControl : BaseUserControl
    {
        protected HiddenField hdnScore;
        protected HtmlInputImage imageField1;
        protected HtmlInputImage imageField2;
        protected HtmlInputImage imageField3;
        protected HtmlInputImage imageField4;
        protected HtmlInputImage imageField5;
        protected string m_ShowPath;

        protected void Page_Load(object sender, EventArgs e)
        {
            this.m_ShowPath = base.BasePath;
            this.m_ShowPath = this.Page.Request.Url.Scheme + "://" + this.Page.Request.Url.Authority + this.m_ShowPath;
        }

        public int Score
        {
            get
            {
                return DataConverter.CLng(this.hdnScore.Value);
            }
            set
            {
                int num = value;
                if (num > 5)
                {
                    num = 0;
                }
                for (int i = 1; i <= num; i++)
                {
                    ((HtmlInputImage) this.FindControl("imageField" + i.ToString())).Src = "../Images/fstar.gif";
                }
                this.hdnScore.Value = num.ToString();
            }
        }
    }
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -