Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
600
clicking an EditorButton by program
posted

Hi,

 for a button it is possible to write button.PerformClick. Is there something similar for EditorButtons ?

 Thanks

Hansjörg Wintermantel

  • 37774
    posted

    I don't think that there is an easy way to simulate the button click.  You could certainly do so through the Accessibility model, though I don't think there's an easy way to find a particular button.  In my case, the following code works when I had one button in the ButtonsRight collection:

    this.ultraTextEditor1.AccessibilityObject.GetChild(0).GetChild(1).DoDefaultAction();

    -Matt