Is there a function in C# that can return the Name of the Focused element and display it in a text-box or something?
Assuming WinForms, you can find the active (focused) control using the Form.ActiveControl property and get the name.
Otherwise if this is a WPF project, you could use the FocusManager.GetFocusedElement() method to find it.