protected void Chart1_Click(object sender, ImageMapEventArgs e) { // If user clicks on the map area attribute that corresponds to a legend item if (e.PostBackValue.StartsWith("LegendClick")) { string args = e.PostBackValue.Split('/')[1]; // Identify which legend item was clicked int index = int.Parse(args); // Legend item result LegendItem legendItem = this.Chart1.Legends[0].CustomItems[index]; // Resets all radio button images to be unchecked foreach (LegendItem item in this.Chart1.Legends[0].CustomItems) { item.Cells[0].ImageTransparentColor = Color.Black; item.Cells[0].Image = "radio_button_unchecked.gif"; } this.Chart1.Series[0].ChartType = (SeriesChartType)Enum.Parse(typeof(SeriesChartType), legendItem.Cells[1].Text, true); this.Chart1.Series[0].BorderWidth = this.Chart1.Series[0].ChartType == SeriesChartType.Line ? 3 : 1; legendItem.Cells[0].Image = "radio_button_checked.gif"; legendItem.Cells[0].ImageTransparentColor = Color.Green; } }
/* ---------------------------------------------------------------------------------------- * Funcion que genera los mensajes y acciones por cada uno de los * pasos necesarios para la implementacion del portal de cotizador * de seguros de autos de PRYBE * ----------------------------------------------------------------------------------------*/ protected void Implementa_Clicked(Object sender, ImageMapEventArgs e) { /* Recibe el valor postback de la selección del usuario y ejecuta una acción y/o mensaje dependiendo el valor */ // Paso 1: Descargar formatos de 'Verificación de requisitos previos' if (e.PostBackValue.Contains("Paso1")) { X.Msg.Confirm("Paso 1: Descargar formatos de 'Verificación de requisitos previos y deposito bancario'", "Descargue e imprima el formato para verificar que cumpla con los requisitos previos" + " para el uso del portal y para llevar a cabo la capacitación web/presencial", new JFunction { Fn = "Paso1" }).Show(); } // Paso 2: Enviar formatos de 'Verificación de requisitos previos' a PRYBE else if (e.PostBackValue.Contains("Paso2")) { X.Msg.Confirm("Paso 2: Enviar formatos de 'Verificación de requisitos previos y deposito bancario' a PRYBE", "Una vez que verificados los requerimientos y lleno el formato, escanearlo y enviarlo " + "por correo electronico a PRYBE para su validación", new JFunction { Fn = "EnviaMail" }).Show(); } // Paso 3: Descargar formatos de 'Solicitud de usuarios' y 'Carta responsiva' else if (e.PostBackValue.Contains("Paso3")) { X.Msg.Confirm("Paso 3: Descargar formatos de 'Solicitud de usuarios' y 'Carta responsiva'", "Descargue los formatos de 'Solicitud de usuarios' y 'Carta responsiva' e imprima un juego por" + "cada ejecutivo que tendra acceso al portal de cotización", new JFunction { Fn = "Paso3" }).Show(); } // Paso 4: Enviar solicitud de creación de usuarios requisitada a PRYBE else if (e.PostBackValue.Contains("Paso4")) { X.Msg.Confirm("Paso 4: Enviar solicitud de creación de usuarios requisitada a PRYBE", "Envie los formatos escaneados por correo electronico a PRYBE para la creación de" + " las cuentas de usuario", new JFunction { Fn = "EnviaMail" }).Show(); } // Paso 5: Recibira por correo electronico la confirmación y cuentas de usuario else if (e.PostBackValue.Contains("Paso5")) { GeneraMensaje("Paso 5: Recibira por correo electronico la confirmación y cuentas de usuario", "Tras validar la solicitud de creación de usuarios recibira una notificación cada ejecutivo" + "con su nombre de usuario y contraseña, y una notificación de creación correcta al encargado" + "de la sucursal", 'I'); } // Paso 6: Generar acceso directo else if (e.PostBackValue.Contains("Paso6")) { X.Msg.Confirm("Paso 6: Generar acceso directo", "El acceso directo comenzara a " + "descargarse en su carpeta de descargas, puede accesar al portal de cotización dando doble clic en el icono llamado " + "'Autos PRYBE' y acceder con el nombre de usuario y contraseña que se le proporciono", new JFunction { Fn = "Paso6" }).Show(); } // Selección incorrecta. else { GeneraMensaje("Alto!!!", "No selecciono una opcion valida, presione sobre los recuadros de la imagen", 'W'); } }
//https://stackoverflow.com/questions/42563240/pie-chart-slice-click private void Chart1_Click(object sender, System.Web.UI.WebControls.ImageMapEventArgs e) { string x = ""; //pt.ToolTip. }
protected void Chart1_Click(object sender, ImageMapEventArgs e) { if (e.PostBackValue.StartsWith("LegendClick")) { int index = int.Parse(e.PostBackValue.Split('/')[1]); // Legend item result LegendItem legendItem = this.Chart1.Legends["Default"].CustomItems[index]; // series item selected Series selectedSeries = this.Chart1.Series[index]; if (selectedSeries.Enabled) { selectedSeries.Enabled = false; legendItem.Cells[0].Image = string.Format(@"chk_unchecked.png"); legendItem.Cells[0].ImageTransparentColor = Color.Red; } else { selectedSeries.Enabled = true; legendItem.Cells[0].Image = string.Format(@"chk_checked.png"); legendItem.Cells[0].ImageTransparentColor = Color.Red; } this.Prepare(); } }
protected virtual void OnClick (ImageMapEventArgs e) { if (Events != null) { ImageMapEventHandler eh = (ImageMapEventHandler) Events [ClickEvent]; if (eh!= null) eh (this, e); } }
/// <devdoc> /// <para>Called when the user clicks the ImageMap.</para> /// </devdoc> protected virtual void OnClick(ImageMapEventArgs e) { ImageMapEventHandler clickHandler = (ImageMapEventHandler)Events[EventClick]; if (clickHandler != null) { clickHandler(this, e); } }
protected void Chart1_Click(object sender, ImageMapEventArgs e) { int pointIndex = int.Parse(e.PostBackValue); Series series = Chart1.Series["My series"]; if (pointIndex >= 0 && pointIndex < series.Points.Count) { series.Points[pointIndex].CustomProperties += "Exploded=true"; } }
protected virtual void OnClick(ImageMapEventArgs e) { ImageMapEventHandler handler = (ImageMapEventHandler)base.Events[EventClick]; if (handler != null) { handler(this, e); } }
protected virtual void OnClick(ImageMapEventArgs e) { if (Events != null) { ImageMapEventHandler eh = (ImageMapEventHandler)Events [ClickEvent]; if (eh != null) { eh(this, e); } } }
protected void ButtonsMap_Clicked(object sender, ImageMapEventArgs e) { // When a user clicks the "Background" hot spot, // display the hot spot's value. if (e.PostBackValue == "Background") { // string coordinates = Buttons.HotSpots[3].GetCoordinates(); // Msg.Text = "You selected the " + e.PostBackValue + "<br />" + // "The coordinates are " + coordinates; } }
private void Chart1_Click(object sender, System.Web.UI.WebControls.ImageMapEventArgs e) { // read coordinates from postback value Point point = (Point)(new PointConverter()).ConvertFromInvariantString(e.PostBackValue); // Conver pixels to percentage coordinates and set legend position Chart1.Annotations[0].X = point.X * 100F / ((float)(Chart1.Width.Value - 1)); Chart1.Annotations[0].Y = point.Y * 100F / ((float)(Chart1.Height.Value - 1)); AdjustAnnotationControls(); SetEditBoxes(); }
protected void MapImage_Click(object sender, ImageMapEventArgs e) { switch (e.PostBackValue) { case "0": Scroll(-0.5, -0.5); break; case "1": Scroll(0, -0.5); break; case "2": Scroll(0.5, -0.5); break; case "3": Scroll(-0.5, 0); break; case "4": ZoomIn(); break; case "5": Scroll(0.5, 0); break; case "6": Scroll(-0.5, 0.5); break; case "7": Scroll(0, 0.5); break; case "8": Scroll(0.5, 0.5); break; } }
protected void imgMapSolarSystem_Click(object sender, ImageMapEventArgs e) { ifSelectResult.Attributes["src"] = "http://zh.wikipedia.org/wiki/" + e.PostBackValue; switch (e.PostBackValue) { case "太阳": //当用户单击太阳 lbDirection.Text = "太阳是位于太阳系中心的恒星."; break; case "水星": lbDirection.Text = "水星是太阳系最内侧同时也是最小的行星."; break; case "金星": lbDirection.Text = "金星是离太阳第二近的行星."; break; case "地球": lbDirection.Text = "地球是太阳的第三颗行星. 同时也是我们所居住的世界, 又称为蓝星."; break; case "火星": lbDirection.Text = "火星是太阳系中离太阳第四近的行星."; break; case "木星": lbDirection.Text = "木星是太阳的第五颗行星同时也是太阳系最大的行星."; break; case "土星": lbDirection.Text = "土星是自太阳起第七颗行星, 也是太阳系中仅次于木星第二大的行星."; break; case "天王星": lbDirection.Text = "天王星是自太阳起第七颗行星, 同时也是太阳系中第三大和第四重的行星."; break; case "海王星": lbDirection.Text = "海王星是我们的太阳系中自太阳起第八颗行星."; break; default: break; } }
private void Chart1_Click(object sender, System.Web.UI.WebControls.ImageMapEventArgs e) { // read coordinates from postback value Point point = (Point)(new PointConverter()).ConvertFromInvariantString(e.PostBackValue); // Conver pixels to percentage coordinates and set legend position Chart1.Titles[0].Position.X = point.X * 100F / ((float)(Chart1.Width.Value - 1)); Chart1.Titles[0].Position.Y = point.Y * 100F / ((float)(Chart1.Height.Value - 1)); AdjustLegendControls(); // Set text fields values TextBoxX.Text = Chart1.Titles[0].Position.X.ToString(); TextBoxY.Text = Chart1.Titles[0].Position.Y.ToString(); TextBoxWidth.Text = Chart1.Titles[0].Position.Width.ToString(); TextBoxHeight.Text = Chart1.Titles[0].Position.Height.ToString(); }
private void Chart1_Click(object sender, System.Web.UI.WebControls.ImageMapEventArgs e) { if (!String.IsNullOrEmpty(e.PostBackValue)) { // Change selected item from combo box. if (e.PostBackValue == "Chart Area 1") { AreaOrder.SelectedIndex = 5; } else if (e.PostBackValue == "Chart Area 2") { AreaOrder.SelectedIndex = 1; } else if (e.PostBackValue == "Chart Area 3") { AreaOrder.SelectedIndex = 0; } this.ReorderChart(); } }
/// <summary> /// Handles the Click event of the Chart1 control. /// </summary> /// <param name="sender">The source of the event.</param> /// <param name="e">The <see cref="System.Web.UI.WebControls.ImageMapEventArgs"/> instance containing the event data.</param> protected void Chart1_Click(object sender, ImageMapEventArgs e) { this.Chart1.Titles["ClickedElement"].Text = "Nothing"; string[] input = e.PostBackValue.Split(':'); if (input.Length == 2) { string[] seriesData = input[1].Split(','); if (input[0].Equals("series")) { this.Chart1.Titles["ClickedElement"].Text = "Last Clicked Element: " + seriesData[0] + " - Data Point #" + seriesData[1]; } else if (input[0].Equals("chart")) { // hit test of X and Y click point HitTestResult hitTestResult = this.Chart1.HitTest(Int32.Parse(seriesData[0]), Int32.Parse(seriesData[1])); if (hitTestResult != null) { this.Chart1.Titles["ClickedElement"].Text = "Last Clicked Element: " + hitTestResult.ChartElementType.ToString(); } } } }
private void myChart_Click(object sender, System.Web.UI.WebControls.ImageMapEventArgs e) { string PO_Id = e.PostBackValue; Response.Redirect(string.Format("Details.aspx?PO_Id={0}", PO_Id)); }
public void ChartClick(object o, System.Web.UI.WebControls.ImageMapEventArgs e) { ChartModel.ChartClick(o, e); UpdateView(); }
public void DoOnBubbleEven (Object source, ImageMapEventArgs e) { base.OnBubbleEvent (source, e); }
public void DoOnClick (ImageMapEventArgs e) { base.OnClick (e); }
public static void ImageMapClickHandler3 (object sender, ImageMapEventArgs e) { WebTest.CurrentTest.UserData = "ImageMapClickHandler"; }
private static void ImageMapClickHandler2 (object sender, ImageMapEventArgs e) { WebTest.CurrentTest.UserData = e.PostBackValue; }
// Вызов по ссылке на карте protected void VoteMap_Clicked(Object sender, ImageMapEventArgs e) { switch (Name_Url.Text.ToString()) { case "Otdelen": Url_Map(e.PostBackValue.ToString(), "Room"); DeviceMain_room(e.PostBackValue.ToString()); Name_Url.Text = "Room"; break; case"Building_child": Url_Map(e.PostBackValue.ToString(), "Otdelen"); Name_Url.Text = "Otdelen"; break; case "Building": Url_Map(e.PostBackValue.ToString(), "Building"); Name_Url.Text = "Building_child"; break; } if (IDLinkClaim.Rows.Count > 0) { for (int i = 0; i < IDLinkClaim.Rows.Count; i++) { arrayList.Add(new Item() { code = i+1, value = IDLinkClaim.Rows[i].Cells[1].Text.ToString(), id = IDLinkClaim.Rows[i].Cells[2].Text.ToString() }); } } arrayList.Add(new Item() { code = IDLinkClaim.Rows.Count+1, value = "value1", id = e.PostBackValue.ToString() }); IDLinkClaim.DataSource = arrayList; IDLinkClaim.DataBind(); }
protected void ImgeMap_Click(object sender, ImageMapEventArgs e) { ViewState["fulldept"] = e.PostBackValue.ToString(); if (e.PostBackValue.Substring(0, 3) == "999") { ViewState["dept"] = e.PostBackValue.Substring(3, e.PostBackValue.Length - 3); ViewState["con"] = " ( convert(char(7),time,120)='" + e.PostBackValue.Substring(3, e.PostBackValue.Length - 3) + "') and ISNULL( PitResult,'')!='' "; } else { ViewState["con"] = " ( convert(char(7),time,120)='" + e.PostBackValue + "') "; ViewState["dept"] = e.PostBackValue; } InfoBind(); }
/// </summary> /// <param name="sender"></param> /// <param name="e"></param> protected void Grafico_Click(object sender, ImageMapEventArgs e) { try { int pointIndex = int.Parse(e.PostBackValue); Series series = Grafico.Series["Leyendas"]; if (pointIndex >= 0 && pointIndex < series.Points.Count) { series.Points[pointIndex].CustomProperties = string.Empty; series.Points[pointIndex].CustomProperties += "Exploded=true"; } } catch (Exception po_exception) { String vs_error_usuario = "Ocurrió un error al enfocar la sección del gráfico."; this.lanzarExcepcion(po_exception, vs_error_usuario); } }
protected void Chart2Click(object sender, ImageMapEventArgs e) { Response.Redirect("SafeChart1.aspx?fid=2"); }
protected void MainChart_Click(object sender, ImageMapEventArgs e) { try { DateTime targetDate = DateTime.Parse(e.PostBackValue.Split(',')[0]); // Clear Data foreach (var item in ChartBubbleDay.Series) { item.Points.Clear(); } // Day DrawBubble(ChartBubbleDay, targetDate, targetDate); } catch (Exception) { throw; } }
protected void SetInjury(object sender, ImageMapEventArgs e) { imageMapClick = e.PostBackValue; if (!injurylist.Contains(imageMapClick)) { injurylist.Add(imageMapClick); pnlTest = new InjuryMiniPanel((int)Session["Control_Increment"], imageMapClick); pnlTest.ID = "pnlInjury_" + ((int)Session["Control_Increment"]); panelList.Add(pnlTest); Session["Control_Increment"] = ((int) Session["Control_Increment"]) + 1; } else { injurylist.Remove(imageMapClick); foreach (InjuryMiniPanel o in panelList) { if (o.Name.Equals(imageMapClick)) { pnlInjuryList.Controls.Remove(o); panelList.Remove(o); break; } } } this.Page_Load(sender, e); }
protected void ImageMap1_Click(object sender, ImageMapEventArgs e) { }
private void ImageMapClickHandler (object sender, ImageMapEventArgs e) { clicked = true; pbValue = e.PostBackValue; }
protected void ChartBubble_Click(object sender, ImageMapEventArgs e) { try { var paras = e.PostBackValue.Split('-'); // X axis for (int i = 0; i < MainChart.Series[0].Points.Count(); i++) { DailyDateList.Add(DateTime.FromOADate(MainChart.Series[0].Points[i].XValue)); } // Clear Data foreach (var item in ChartFocus.Series) { item.Points.Clear(); } // Draw GridViewRow row = GridView1.SelectedRow; DrawSingleChart(new BrokerItem() { Name = paras[0], Branch = paras[1] }, ChartFocus); // Copy ChartFocus.Series["Price"]["PriceUpColor"] = "Red"; ChartFocus.Series["Price"]["PriceDownColor"] = "Green"; foreach (var item in MainChart.Series["Price"].Points) { ChartFocus.Series["Price"].Points.Add(item); } } catch (Exception) { throw; } }
/// </summary> /// <param name="sender"></param> /// <param name="e"></param> protected void Grafico_Click(object sender, ImageMapEventArgs e) { try { int pointIndex = int.Parse(e.PostBackValue); Series series = Grafico.Series["Leyendas"]; CargaGrafico(Convert.ToInt32(ddl_proyecto.SelectedValue), Convert.ToDateTime(txt_fechaInicio.Text), Convert.ToDateTime(txt_fechaFin.Text), (lbx_usuarios.SelectedIndex == 0 ? string.Empty : lbx_usuarios.SelectedValue.ToString())); if (pointIndex >= 0 && pointIndex < series.Points.Count) { series.Points[pointIndex].CustomProperties = string.Empty; series.Points[pointIndex].CustomProperties += "Exploded=true"; } } catch (Exception po_exception) { String vs_error_usuario = "Ocurrió un error al enfocar la sección del gráfico."; this.lanzarExcepcion(po_exception, vs_error_usuario); } }
public void ImageMap_BubbleEvent () { PokerImageMap imageMap = new PokerImageMap (); ResetEvents (); ImageMapEventArgs args = new ImageMapEventArgs ("HotSpotName"); imageMap.Click += new ImageMapEventHandler (ImageMapClickHandler); Assert.AreEqual (false, clicked, "BeforeClick"); imageMap.DoOnBubbleEven (imageMap, args); Assert.AreEqual (true, clicked, "AfterClick"); }
protected void ImageMap1_Click(object sender, ImageMapEventArgs e) { string[] cellBoundaries = e.PostBackValue.Split(' '); string sdssServiceBasePath = "http://localhost:8080/SDSS/rest?" + "skip_auth=true&method=METHOD3&format=xml&start=0&rows=100"; sdssServiceBasePath += "&dblRightAscensionMin=" + cellBoundaries[0] + "&dblRightAscensionMax=" + cellBoundaries[1] + "&dblDeclensionMin=" + cellBoundaries[2] + "&dblDeclensionMax=" + cellBoundaries[3]; HttpWebRequest myReq = (HttpWebRequest)WebRequest.Create(sdssServiceBasePath); WebResponse serviceResponse = myReq.GetResponse(); hlGSCObjects.NavigateUrl = sdssServiceBasePath; XPathNavigator nav; XPathDocument docNav; XPathNodeIterator NodeIter; string strExpression; // Open the XML. docNav = new XPathDocument(serviceResponse.GetResponseStream()); // Create a navigator to query with XPath. nav = docNav.CreateNavigator(); //expression to read GSC objects strExpression = "/myResponse/body/response/numFound"; // Select the node and place the results in an iterator. NodeIter = nav.Select(strExpression); NodeIter.MoveNext(); Label1.Text = "GSC Objects Found in Cell : " + NodeIter.Current.Value; strExpression = "/myResponse/body/response/docs"; //HtmlGenericControl gen = new HtmlGenericControl("table"); //Table t = new Table(); TableRow row = new TableRow(); TableCell cell = new TableCell(); NodeIter = nav.Select(strExpression); //Iterate through the results showing the element value. while (NodeIter.MoveNext()) { row = new TableRow(); //gen.InnerHtml += "<tr>"; XPathNodeIterator innerIterator = NodeIter.Current.SelectChildren(XPathNodeType.Element); while (innerIterator.MoveNext()) { cell = new TableCell(); cell.Text = innerIterator.Current.Value; row.Cells.Add(cell); } tblGSCObjects.Rows.Add(row); } //////////////////////////////////////////////////////////////////////// sdssServiceBasePath = "http://localhost:8080/SDSS/rest?" + "skip_auth=true&method=METHOD2&format=xml&start=0&rows=100"; sdssServiceBasePath += "&dblRightAscensionMin=" + cellBoundaries[0] + "&dblRightAscensionMax=" + cellBoundaries[1] + "&dblDeclensionMin=" + cellBoundaries[2] + "&dblDeclensionMax=" + cellBoundaries[3]; myReq = (HttpWebRequest)WebRequest.Create(sdssServiceBasePath); serviceResponse = myReq.GetResponse(); hlSDSSObject.NavigateUrl = sdssServiceBasePath; // Open the XML. docNav = new XPathDocument(serviceResponse.GetResponseStream()); // Create a navigator to query with XPath. nav = docNav.CreateNavigator(); //expression to read GSC objects strExpression = "/myResponse/body/size"; // Select the node and place the results in an iterator. NodeIter = nav.Select(strExpression); NodeIter.MoveNext(); Label2.Text = "SDSS Objects Found in Cell : " + NodeIter.Current.Value; strExpression = "/myResponse/body/*"; NodeIter = nav.Select(strExpression); //Iterate through the results showing the element value. while (NodeIter.MoveNext()) { if (NodeIter.Current.LocalName == "size") { Label2.Text = "SDSS Objects Found in Cell : " + NodeIter.Current.Value; } else { row = new TableRow(); //gen.InnerHtml += "<tr>"; XPathNodeIterator innerIterator = NodeIter.Current.SelectChildren(XPathNodeType.Element); while (innerIterator.MoveNext()) { cell = new TableCell(); cell.Text = innerIterator.Current.Value; row.Cells.Add(cell); } tblSDSSObjects.Rows.Add(row); } } }
protected void Chart1_Click(object sender, ImageMapEventArgs e) { this.DetailSource.SelectParameters["RegionName"].DefaultValue = e.PostBackValue; this.GridView.Caption = String.Format("{0} Region", e.PostBackValue); }
/// <devdoc> /// <para>Called when the user clicks the ImageMap.</para> /// </devdoc> protected virtual void OnClick(ImageMapEventArgs e) { ImageMapEventHandler clickHandler = (ImageMapEventHandler)Events[EventClick]; if (clickHandler != null) { clickHandler(this, e); } }
protected void ImageMap1_Click(object sender, ImageMapEventArgs e) { runjQueryCode("$('#my_popup').popup();"); }
protected virtual new void OnClick(ImageMapEventArgs e) { }
protected virtual new void OnClick(ImageMapEventArgs e) { }