Jump to content
Sign in to follow this  
randallc

Set keyboard focus on ListBox

Recommended Posts

randallc

Hi,

Can someone help me please with these commands?

I still have to click on the list to get keyboard input working?

Can i just send a mouse click to the control or something?

  Case $MSG = $btnME

   $MEreg = RegRead($MEregMisc, "MEreg1")

   $MEreg1 = 0

   If $MEreg <> "ME" Then ;$MEreg1=1

    If (_GUICtrlListViewGetSelectedCount ($LV_FILELIST3)) Then

     $TextLineAnswer = _GUICtrlListViewGetItemText ($LV_FILELIST3, -1)

    Else

     $TextLineAnswer = _GUICtrlListViewGetItemText ($LV_FILELIST3, 0)

    EndIf

    $MEreg = "WIZ"

    $MEreg1 = 0

    RegWrite($MEregMisc, "MEreg1", "REG_SZ", $MEreg)

    RegWrite($MEregMisc, "MEreg1Answer", "REG_SZ", $TextLineAnswer)

    Exit

   EndIf

textpicker.jpg

Best, Randall

Edited by randallc

Share this post


Link to post
Share on other sites
randallc

Hi, Gary,

Yes, I showe dthe wrong snip of program;

  GUICtrlSetState($TAB_WINDOW, $GUI_SHOW)

  GUICtrlSetState($tabListPicker, $GUI_SHOW)

  GUICtrlSetState($LV_FILELIST3, $GUI_HIDE)

  ControlListView($TAB_WINDOW, "", $LV_FILELIST3, "SelectClear")

  _BuildList3($LV_FILELIST3, $Liner)

  GUICtrlSetPos($LV_FILELIST3, 37 - .42 * $ExtraRight, 40, 415 + 1 * $ExtraRight + 2 * $ExtraRight, $W_HEIGHT - 152)

  ControlListView($TAB_WINDOW, "", $LV_FILELIST3, "Select", 0)

  GUICtrlSetState($LV_FILELIST3, $GUI_SHOW)

  GUICtrlSetState($LV_FILELIST3, $GUI_FOCUS)

This does have the GUI_FOCUS;

Perhaps I need to put it somewhere else as well?

Best, Randall

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.