当前位置: 首页>>代码示例>>C#>>正文


C# HtmlControls.HtmlInputButton类代码示例

本文整理汇总了C#中System.Web.UI.HtmlControls.HtmlInputButton的典型用法代码示例。如果您正苦于以下问题:C# HtmlInputButton类的具体用法?C# HtmlInputButton怎么用?C# HtmlInputButton使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


HtmlInputButton类属于System.Web.UI.HtmlControls命名空间,在下文中一共展示了HtmlInputButton类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: AddActions

        private void AddActions(HtmlGenericControl container)
        {
            using (HtmlGenericControl actions = new HtmlGenericControl("div"))
            {
                actions.Attributes.Add("class", "actions");

                using (HtmlGenericControl buttons = new HtmlGenericControl("div"))
                {
                    buttons.Attributes.Add("class", "ui buttons");

                    using (HtmlInputButton cancelButton = new HtmlInputButton())
                    {
                        cancelButton.Attributes.Add("class", "ui red button");
                        cancelButton.Value = Titles.Cancel;

                        buttons.Controls.Add(cancelButton);
                    }

                    using (HtmlInputButton verifyButton = new HtmlInputButton())
                    {
                        verifyButton.ID = "VerifyButton";
                        verifyButton.Attributes.Add("class", "ui green button");
                        verifyButton.Value = Titles.Verify;
                        verifyButton.Attributes.Add("title", "CTRL + RETURN");
                        buttons.Controls.Add(verifyButton);
                    }

                    actions.Controls.Add(buttons);
                }

                container.Controls.Add(actions);
            }
        }
开发者ID:roczj,项目名称:mixerp,代码行数:33,代码来源:VoucherVerification.ascx.cs

示例2: buttonStyleWhite

 public void buttonStyleWhite(HtmlInputButton button, string message)
 {
     button.Visible = true;
     button.Style.Add("background-color", "white");
     button.Style.Add("color", "red");
     button.Value = message;
 }
开发者ID:Alfre97,项目名称:SYSPARK,代码行数:7,代码来源:ButtonStyle.cs

示例3: Page_Load

		private void Page_Load(object sender, System.EventArgs e) 
		{
			System.Web.UI.HtmlControls.HtmlForm frm = (HtmlForm)FindControl("Form1");
			GHTTestBegin(frm);
			//False
			GHTSubTestBegin("Causes validation = false");
			try 
			{
				System.Web.UI.HtmlControls.HtmlInputButton btn = new System.Web.UI.HtmlControls.HtmlInputButton();
				btn.CausesValidation = false;
				GHTActiveSubTest.Controls.Add(btn);
			}
			catch (Exception ex) 
			{
				GHTSubTestUnexpectedExceptionCaught(ex);
			}
			//true
			GHTSubTestBegin("Causes validation = true");
			try 
			{
				System.Web.UI.HtmlControls.HtmlInputButton btn = new System.Web.UI.HtmlControls.HtmlInputButton();
				btn.CausesValidation = true;
				GHTActiveSubTest.Controls.Add(btn);
			}
			catch (Exception ex) 
			{
				GHTSubTestUnexpectedExceptionCaught(ex);
			}
			GHTTestEnd();
		}
开发者ID:nobled,项目名称:mono,代码行数:30,代码来源:HtmlInputButton_CausesValidation.aspx.cs

示例4: CreateChildControls

		protected override void CreateChildControls()
		{
			Page.ClientScript.RegisterClientScriptBlock(GetType(), "ShowLocationSelectionDialog", CreateShowDialogScript());

			if (ValueControl == null)
				CreateValueControl();

			DisplayControl = new TextBox();
			DisplayControl.ID = "Display";
			DisplayControl.Enabled = false;

			CopyWebAttributes(DisplayControl);
			Controls.Add(DisplayControl);

			HtmlInputButton openDialogButton = new HtmlInputButton();
			if (!Enabled)
				openDialogButton.Attributes.Add("disabled", "disabled");

			openDialogButton.Value = "...";
			openDialogButton.Attributes.Add("class", "epismallbutton");
			openDialogButton.Attributes.Add("onclick", string.Format(
				"ShowLocationSelectionDialog('{0}', document.getElementById('{1}').value, '{2}', '{3}', '{4}', '{5}', '{6}');",
				UriSupport.ResolveUrlBySettings(ControlPath),
				ValueControl.ClientID,
				DisplayControl.ClientID,
				ValueControl.ClientID,
				ContentLanguage.PreferredCulture.Name,
				DialogWidth,
				DialogHeight
			));

			Controls.Add(openDialogButton);
		}
开发者ID:nansen,项目名称:EPiServer.GoogleMapsLocation,代码行数:33,代码来源:InputGoogleMapsLocation.cs

示例5: AddEditor

        protected override Control AddEditor(Control container)
        {
            // Register the javascript needed for the control.
            container.Page.JavaScript(Engine.ManagementPaths.ResolveResourceUrl("~/Scripts/underscore-min.js"));
            container.Page.JavaScript(Engine.ManagementPaths.ResolveResourceUrl("~/Scripts/backbone-min.js"));
            LoadControlScripts(container);
            var control = new Control();
            var textBox = new TextBox {CssClass = "textEditor", ID = Name};
            textBox.ID = textBox.ID;
            control.Controls.Add(textBox);

            var csButton = new HtmlInputButton();

            csButton.Attributes["value"] = ButtonText;
            csButton.Attributes["class"] = string.Format("{0}-selector-button", ButtonClassPrefix);
            csButton.Attributes["data-app-path"] = HttpContext.Current.Request.Url.GetLeftPart(UriPartial.Authority) + HttpContext.Current.Request.ApplicationPath;
            csButton.Attributes["data-image-control-id"] = textBox.ClientID;
            if (PropertyMap != null)
                csButton.Attributes["data-property-map"] = PropertyMapToJson();
            SetCustomAttributes(container, csButton);
            control.Controls.Add(csButton);

            container.Controls.Add(control);
            return control;
        }
开发者ID:grbbod,项目名称:drconnect-jungo,代码行数:25,代码来源:EditableApiSelectorAttribute.cs

示例6: CreateBackupButton

 private void CreateBackupButton(HtmlGenericControl container)
 {
     using (HtmlInputButton backupButton = new HtmlInputButton())
     {
         backupButton.Attributes.Add("class", "ui red button disabled loading");
         backupButton.Value = Titles.BackupNow;
         backupButton.ID = "BackupButton";
         container.Controls.Add(backupButton);
     }
 }
开发者ID:abinabrahamanchery,项目名称:mixerp,代码行数:10,代码来源:DatabaseBackup.ascx.cs

示例7: CreateFlagButton

 private void CreateFlagButton(HtmlGenericControl container)
 {
     using (HtmlInputButton flagButton = new HtmlInputButton())
     {
         flagButton.ID = "FlagButton";
         flagButton.Value = Titles.Flag;
         flagButton.Attributes.Add("class", "ui button");
         container.Controls.Add(flagButton);
     }
 }
开发者ID:roczj,项目名称:mixerp,代码行数:10,代码来源:FlagButton.cs

示例8: AddSaveButton

 private void AddSaveButton(HtmlGenericControl div)
 {
     using (HtmlInputButton button = new HtmlInputButton())
     {
         button.ID = "SaveButton";
         button.Value = Titles.Save;
         button.Attributes.Add("class", "ui small blue button");
         div.Controls.Add(button);
     }
 }
开发者ID:abinabrahamanchery,项目名称:mixerp,代码行数:10,代码来源:BottomPanel.cs

示例9: CreateSaveButton

        private void CreateSaveButton(Control container)
        {
            using (HtmlInputButton saveButton = new HtmlInputButton())
            {
                saveButton.ID = "SaveButton";
                saveButton.Attributes.Add("class", "small ui button red");
                saveButton.Value = Titles.Save;

                container.Controls.Add(saveButton);
            }
        }
开发者ID:nubiancc,项目名称:mixerp,代码行数:11,代码来源:OpeningInventory.ascx.cs

示例10: CreateUndoButton

        private void CreateUndoButton(HtmlGenericControl container)
        {
            using (HtmlInputButton undoButton = new HtmlInputButton())
            {
                undoButton.ID = "UndoButton";
                undoButton.Value = Titles.Undo;
                undoButton.Attributes.Add("class", "ui small red button");

                container.Controls.Add(undoButton);
            }
        }
开发者ID:abinabrahamanchery,项目名称:mixerp,代码行数:11,代码来源:Buttons.cs

示例11: AddSaveButton

        private static void AddSaveButton(HtmlGenericControl container)
        {
            using (HtmlInputButton saveButton = new HtmlInputButton())
            {
                saveButton.ID = "SaveButton";
                saveButton.Attributes.Add("class", "small ui red button");
                saveButton.Value = Titles.Save;

                container.Controls.Add(saveButton);
            }
        }
开发者ID:njmube,项目名称:mixerp,代码行数:11,代码来源:SaveButton.cs

示例12: CreatePrintButton

        private void CreatePrintButton(HtmlGenericControl container)
        {
            using (HtmlInputButton printButton = new HtmlInputButton())
            {
                printButton.ID = "PrintButton";
                printButton.Value = Titles.Print;
                printButton.Attributes.Add("class", "ui button");

                container.Controls.Add(printButton);
            }
        }
开发者ID:JonathanValle,项目名称:mixerp,代码行数:11,代码来源:PrintButton.cs

示例13: CreateUploadButton

        private void CreateUploadButton(HtmlGenericControl container)
        {
            using (HtmlInputButton uploadButton = new HtmlInputButton())
            {
                uploadButton.ID = "UploadButton";
                uploadButton.Value = Titles.Upload;
                uploadButton.Attributes.Add("class", "ui small blue button");

                container.Controls.Add(uploadButton);
            }
        }
开发者ID:abinabrahamanchery,项目名称:mixerp,代码行数:11,代码来源:Buttons.cs

示例14: CreatSaveButton

        private void CreatSaveButton(HtmlGenericControl container)
        {
            using (HtmlInputButton saveButton = new HtmlInputButton())
            {
                saveButton.ID = "SaveButton";
                saveButton.Attributes.Add("class", "ui small green button");
                saveButton.Value = Titles.Save;
                saveButton.Visible = this.ShowSaveButton;

                container.Controls.Add(saveButton);
            }
        }
开发者ID:abinabrahamanchery,项目名称:mixerp,代码行数:12,代码来源:Buttons.cs

示例15: AddCancelButton

        private void AddCancelButton(HtmlGenericControl p)
        {
            using (HtmlInputButton button = new HtmlInputButton())
            {
                button.ID = "CancelButton";
                button.CausesValidation = false;
                button.Value = Titles.Cancel;
                button.Attributes.Add("class", "ui red small submit button");

                p.Controls.Add(button);
            }
        }
开发者ID:abinabrahamanchery,项目名称:mixerp,代码行数:12,代码来源:WithdrawDiv.cs


注:本文中的System.Web.UI.HtmlControls.HtmlInputButton类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。