To add a click event to a button in C # code, I can do this
Button btn = new Button; btn.Click += btn_Click;
What if I have an Ellipse that does not contain Click?
Ellipse e = new Ellipse; e.??? += e_Click;
Perhaps the MouseUp event will serve your purpose. Try
Ellipse ellipse = new Ellipse(); ellipse.MouseUp += ellipse_MouseUp; private void ellipse_MouseUp(object sender, MouseButtonEventArgs e) { ... }
One way to do this is to make the button an ellipse and process the .Click Event handler.
<Button> <Button.Template> <ControlTemplate> <Ellipse .../> </ControlTemplate> </Button.Template> </Button>
Source: https://habr.com/ru/post/1346851/More articles:autocomplete text field for .net with separator support - textconditional visibility jquery - jquerydisable the ubuntu 10.10 splash screen with the command - ubuntu-10.10CSS3 Templates - What is Possible? - cssConverting from varchar to Nvarchar SQLServer 2008 - sql-serverGoogle Static Map API, how to specify maximum zoom level - google-mapsWCF Service Deployment - c #SQLite installation issue with Visual C # 2010 - c #google docs spreadsheet asp.net - asp.nethttps://translate.googleusercontent.com/translate_c?depth=1&rurl=translate.google.com&sl=ru&sp=nmt4&tl=en&u=https://fooobar.com/questions/1346856/what-values-to-use-for-packet-and-frame-size-with-audiounit&usg=ALkJrhgzmhGJ96aLdPzbe-2iZEBRJPjLCgAll Articles