Mark OK button so when i press Enter it will press OK.

Welcome Forums General PowerShell Q&A Mark OK button so when i press Enter it will press OK.

This topic contains 2 replies, has 2 voices, and was last updated by

 
Participant
1 week, 6 days ago.

  • Author
    Posts
  • #181314

    Participant
    Topics: 6
    Replies: 11
    Points: 97
    Rank: Member

    Hello all,

    i have a script with text box which an IP address should be inserted into and after that hit OK.
    my problem is that after inserting the IP, i can press OK only with the mouse, i need the OK button to be pre-marked or somthing like that.

    Thanks in advance.

  • #181332

    Participant
    Topics: 1
    Replies: 1552
    Points: 2,700
    Helping Hand
    Rank: Community Hero

    If you'd use the pure console without any GUI elements you wouldn't need the mouse at all. 😉

  • #181371

    Participant
    Topics: 6
    Replies: 11
    Points: 97
    Rank: Member

    I've found that helpful:

    $button_start.TabIndex = 0

    this marks the start button but, when i click inside the test box, the button is no longer marked.
    how to keep it permanently ,arked so Enter will always click it?

You must be logged in to reply to this topic.