c#

.Net How to get the ID of the clicked Element in a Webbrowser  #angularjs #reactjs

  • We have clicked an image break; default: //!
  • I want to get the HTML Id of the clicked Element in a Webbrowser.
  • Example: If i click the Google Search button it should give me the HTML ID of the clicked element (in this case a button)
  • Stack Overflow works best with JavaScript enabled
  • We have clicked a link break; case “IMG”: //!

Example:
If i click the Google Search button it should give me the HTML ID of the clicked element (in this case a button)

@ng_real_ninja: .Net How to get the ID of the clicked Element in a Webbrowser #angularjs #reactjs

First off, we need to translate the mouse coordinates on the screen, into a Point object:

Now, we can use this element to see what has been clicked:

c#