protected override void OnPreRender(EventArgs e)
        {
            Page.ClientScript.RegisterClientScriptBlock(this.GetType(),
                                                        "RoleMatrixEntryControlScript",
                                                        ResourceHelper.LoadStringFromResource(Assembly.GetExecutingAssembly(), "MCS.Web.WebControls.RoleMatrixEntry.RoleMatrixEntryControlScript.htm"),
                                                        false);

            AccessTicketHtmlAnchor.RegisterScript(this.Page);

            base.OnPreRender(e);
        }
        private Control CreateLinkButton(string linkUrl, string prefix, string imgUrl, string title, string linkScript)
        {
            HtmlAnchor anchor = null;

            if (this.EnableAccessTicket)
            {
                anchor = new AccessTicketHtmlAnchor();

                anchor.ID = this.ClientID + prefix + "_anchor";
                if (linkScript.IsNotEmpty())
                {
                    ((AccessTicketHtmlAnchor)anchor).OnClientAccquiredAccessTicket = linkScript;
                }
            }
            else
            {
                anchor = new HtmlAnchor();

                if (linkScript.IsNotEmpty())
                {
                    anchor.Attributes["onclick"] = linkScript;
                }
            }

            anchor.HRef = linkUrl;
            anchor.Attributes["class"]           = "roleMatrixLink";
            anchor.Attributes["appCodeName"]     = this.AppCodeName;
            anchor.Attributes["appName"]         = this.AppName;
            anchor.Attributes["roleID"]          = this.RoleID;
            anchor.Attributes["appID"]           = this.AppID;
            anchor.Attributes["roleName"]        = this.RoleName;
            anchor.Attributes["roleCodeName"]    = this.RoleCodeName;
            anchor.Attributes["roleDescription"] = this.RoleDescription;
            anchor.Attributes["definitionID"]    = this.DefinitionID.IsNotEmpty() ? this.DefinitionID : this.RoleID;
            anchor.Attributes["readOnlyMode"]    = this.ReadOnly ? "enabled" : "disabled";

            HtmlImage img = new HtmlImage();

            img.Src = imgUrl;
            img.Alt = title;
            img.Attributes["class"] = "roleMatrixIcon";
            anchor.Controls.Add(img);

            return(anchor);
        }
		private Control CreateLinkButton(string linkUrl, string prefix, string imgUrl, string title, string linkScript)
		{
			HtmlAnchor anchor = null;

			if (this.EnableAccessTicket)
			{
				anchor = new AccessTicketHtmlAnchor();

				anchor.ID = this.ClientID + prefix + "_anchor";
				if (linkScript.IsNotEmpty())
					((AccessTicketHtmlAnchor)anchor).OnClientAccquiredAccessTicket = linkScript;
			}
			else
			{
				anchor = new HtmlAnchor();

				if (linkScript.IsNotEmpty())
					anchor.Attributes["onclick"] = linkScript;
			}

			anchor.HRef = linkUrl;
			anchor.Attributes["class"] = "roleMatrixLink";
			anchor.Attributes["appCodeName"] = this.AppCodeName;
			anchor.Attributes["appName"] = this.AppName;
			anchor.Attributes["roleID"] = this.RoleID;
			anchor.Attributes["appID"] = this.AppID;
			anchor.Attributes["roleName"] = this.RoleName;
			anchor.Attributes["roleCodeName"] = this.RoleCodeName;
			anchor.Attributes["roleDescription"] = this.RoleDescription;
			anchor.Attributes["definitionID"] = this.DefinitionID.IsNotEmpty() ? this.DefinitionID : this.RoleID;
			anchor.Attributes["readOnlyMode"] = this.ReadOnly ? "enabled" : "disabled";

			HtmlImage img = new HtmlImage();

			img.Src = imgUrl;
			img.Alt = title;
			img.Attributes["class"] = "roleMatrixIcon";
			anchor.Controls.Add(img);

			return anchor;
		}