void LabelX_MarkupLinkClick(object sender, MarkupLinkClickEventArgs e) { SelectedElementCollection collection = this.usgSource.GetSelectedCells(); if (collection.Count > 0) { GridCell gridCell = collection[0] as GridCell; if (gridCell != null) { GridRow gridRow = gridCell.Parent as GridRow; if (gridRow != null) { frmReserveOperate frmReserveOperate = new frmReserveOperate(); frmReserveOperate.BringToFront(); frmReserveOperate.StartPosition = FormStartPosition.CenterScreen; frmReserveOperate.SourceBillGuid = gridRow.Cells["colSourceBillGuid"].Value.ToGuid(); frmReserveOperate.SourceBillLineGuid = gridRow.Cells["colSourceBillLineGuid"].Value.ToGuid(); frmReserveOperate.SourceBillNo = gridRow.Cells["colSourceBillNo"].Value.ToStringHasNull(); frmReserveOperate.SourceBillType = gridRow.Cells["colSourceBillType"].Value.ToStringHasNull(); frmReserveOperate.RefreshParentForm += delegate { BindSuperGrid(1); }; frmReserveOperate.ShowDialog(); } } } }
void lxc_MarkupLinkClick(object sender, MarkupLinkClickEventArgs e) { SelectedElementCollection collection = this.noticedPanel.GetSelectedCells(); if (collection.Count > 0) { GridCell gridCell = collection[0] as GridCell; if (gridCell != null) { GridRow gridRow = gridCell.Parent as GridRow; if (gridRow != null) { if (MessageBox.Show("请确认是否通知采购员取消采购?", "操作提示", MessageBoxButtons.OKCancel, MessageBoxIcon.Question) == DialogResult.OK) { Guid?noticeGuid = gridRow.Cells["colNoticeGuid"].Value.ToGuid(); bool flag = noticeLogic.CancelPurchaseNotice(new ORD_PurchaseNoticeParam() { NoticeGuid = noticeGuid }); if (flag) { BindSuperGrid(); if (RefreshParentForm != null) { RefreshParentForm(); } } } } } } //MessageBox.Show(noticeGuid.ToStringHasNull()); // //SelectedElementCollection col = this.noticedPanel.GetSelectedRows(); // //GridRow row= col[0] as GridRow; }
void MyGridLabelXEditControlMarkupLinkClick( object sender, MarkupLinkClickEventArgs e) { ProcessStartInfo sInfo = new ProcessStartInfo(e.HRef); Process.Start(sInfo); }
/// <summary> /// Open browser on click /// </summary> private void OnMarkupLinkClick(object sender, MarkupLinkClickEventArgs e) { var href = e.HRef; if (href.StartsWith("http:") || href.StartsWith("https:") || href.StartsWith("ftp:")) { try { Process.Start(href); } catch { // Ignore } } }
private void _description_MarkupLinkClick(object sender, MarkupLinkClickEventArgs e) { try { if (Regex.IsMatch(e.HRef, @"\b(https?|ftp|file)://[-A-Z0-9+&@#/%?=~_|$!:,.;]*[A-Z0-9+&@#/%=~_|$]", RegexOptions.IgnoreCase)) { #pragma warning disable SCS0001 // Command injection possible in {1} argument passed to '{0}' Process.Start(e.HRef); #pragma warning restore SCS0001 // Command injection possible in {1} argument passed to '{0}' } } catch { // Ignore the error because the link is simply not trusted. } }
protected virtual void OnMarkupLinkClick(MarkupLinkClickEventArgs e) { if (this.MarkupLinkClick != null) MarkupLinkClick(this, e); }
private void labelX3_MarkupLinkClick(object sender, MarkupLinkClickEventArgs e) { System.Diagnostics.Process.Start("http://www.devcomponents.com/kb/questions.php?questionid=5"); }
private void TextPanelMarkupLinkClick(object sender, MarkupLinkClickEventArgs e) { MessageBoxEx.InvokeMarkupLinkClick(sender, e); }
private void labelX2_MarkupLinkClick(object sender, MarkupLinkClickEventArgs e) { System.Diagnostics.Process.Start(e.HRef); }
/// <summary> /// Occurs when text markup link is clicked. /// </summary> private void TabStripTitleTextMarkupLinkClick(object sender, MarkupLinkClickEventArgs e) { if (TitleTextMarkupLinkClick != null) TitleTextMarkupLinkClick(this, new MarkupLinkClickEventArgs(e.Name, e.HRef)); }
private void MarkupLinkClick(object sender, MarkupLinkClickEventArgs e) { OnTitleTextMarkupLinkClick(e); }
/// <summary> /// Raises MarkupLinkClick event. /// </summary> /// <param name="e">Provides event arguments.</param> protected virtual void OnMarkupLinkClick(MarkupLinkClickEventArgs e) { MarkupLinkClickEventHandler handler = MarkupLinkClick; if (handler != null) handler(this, e); }