• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

C# HtmlControls.HtmlInputButton类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

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



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


示例16: LoadServices

        private void LoadServices()
        {
            ConnectorDataContext db = new ConnectorDataContext();

            Stopwatch w = Stopwatch.StartNew();
            List<ServiceInstance> sInstance = db.ServiceInstances.Where(s => s.Service.name != "SocialTFS").ToList();
            w.Stop();
            ILog log = LogManager.GetLogger("QueryLogger");
            log.Info(" Elapsed time: " + w.Elapsed + ", select all service instances different from 'SocialTFS' to load them");

            foreach (var item in sInstance)
            {
                HtmlTableCell name = new HtmlTableCell();
                HtmlTableCell service = new HtmlTableCell();
                HtmlTableCell host = new HtmlTableCell();
                HtmlTableCell edit = new HtmlTableCell();
                HtmlTableCell delete = new HtmlTableCell();

                name.InnerText = item.name;
                service.InnerText = item.Service.name;
                host.InnerText = item.host;

                IService iService = ServiceFactory.getService(item.Service.name);

                if (iService.GetPrivateFeatures().Contains(FeaturesType.MoreInstance) || iService.GetPrivateFeatures().Contains(FeaturesType.Labels))
                {
                    HtmlInputButton editBT = new HtmlInputButton();
                    editBT.Attributes.Add("title", "Edit " + item.name);
                    editBT.Attributes.Add("class", "edit");
                    editBT.Value = item.id.ToString();
                    edit.Attributes.Add("class", "center");
                    edit.Controls.Add(editBT);
                }

                HtmlInputButton deleteBT = new HtmlInputButton();
                deleteBT.Attributes.Add("title", "Delete " + item.name);
                deleteBT.Attributes.Add("class", "delete");
                deleteBT.Value = item.id.ToString();
                delete.Attributes.Add("class", "center");
                delete.Controls.Add(deleteBT);

                HtmlTableRow tr = new HtmlTableRow();
                tr.ID = "Row" + item.id;
                tr.Cells.Add(name);
                tr.Cells.Add(service);
                tr.Cells.Add(host);
                tr.Cells.Add(edit);
                tr.Cells.Add(delete);

                ServiceTable.Rows.Add(tr);
            }
        }
开发者ID:CosimoLovascio,项目名称:SocialCDE-ProxyServer-VSclient,代码行数:52,代码来源:Services.aspx.cs


示例17: CreateAddButton

        private void CreateAddButton(HtmlGenericControl container)
        {
            if (!string.IsNullOrWhiteSpace(this.AddNewUrl))
            {
                using (HtmlInputButton addButton = new HtmlInputButton())
                {
                    addButton.ID = "AddNewButton";
                    addButton.Value = Titles.AddNew;
                    addButton.Attributes.Add("class", "ui button");
                    addButton.Attributes.Add("onclick", "window.location='" + this.ResolveUrl(this.AddNewUrl) + "'");

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


示例18: CreateActionField

        private static void CreateActionField(TableRow row)
        {
            using (TableCell cell = new TableCell())
            {
                using (HtmlInputButton addButton = new HtmlInputButton())
                {
                    addButton.ID = "AddButton";
                    addButton.Attributes.Add("class", "small ui button blue");
                    addButton.Value = Titles.Add;
                    addButton.Attributes.Add("title", "Ctrl + Return");

                    cell.Controls.Add(addButton);
                }
                row.Cells.Add(cell);
            }
        }
开发者ID:JonathanValle,项目名称:mixerp,代码行数:16,代码来源:Action.cs


示例19: AddButton

        private void AddButton(TableRow row)
        {
            using (TableCell cell = this.GetCell())
            {
                using (HtmlInputButton addButton = new HtmlInputButton())
                {
                    addButton.ID = "AddButton";
                    addButton.Value = Titles.Add;
                    addButton.Attributes.Add("class", "ui small red button");

                    cell.Controls.Add(addButton);
                }

                row.Controls.Add(cell);
            }
        }
开发者ID:abinabrahamanchery,项目名称:mixerp,代码行数:16,代码来源:GridInlineForm.cs


示例20: AddButton

        private void AddButton()
        {
            using (HtmlGenericControl div = new HtmlGenericControl())
            {
                div.TagName = "div";
                div.Attributes.Add("class", "vpad16");

                using (HtmlInputButton reorderButton = new HtmlInputButton())
                {
                    reorderButton.Attributes.Add("class", "ui positive button");
                    reorderButton.Attributes.Add("onclick", "ReorderInputButtonClick()");
                    reorderButton.Value = Titles.PlaceReorderRequests;
                    div.Controls.Add(reorderButton);
                    this.Placeholder1.Controls.Add(div);
                }
            }
        }
开发者ID:njmube,项目名称:mixerp,代码行数:17,代码来源:Reorder.ascx.cs



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


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# HtmlControls.HtmlInputCheckBox类代码示例发布时间:2022-05-26
下一篇:
C# HtmlControls.HtmlImage类代码示例发布时间:2022-05-26
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap