+ Reply to Thread
Results 1 to 4 of 4

By a double click in listbox, a textbox to fill another UserForm

  1. #1
    Registered User
    Join Date
    08-09-2011
    Location
    Arnhem, NL
    MS-Off Ver
    Excel 2007
    Posts
    3

    By a double click in listbox, a textbox to fill another UserForm

    Dear Forum Users,

    This is my first post, I am very poor in English and I hope you understand my question.

    I have a UserForm with 8 text boxes. (UserForm1) on the UserForm is a button that opens another UserForm
    On this second UserForm (FrmMedewerkers) is also a listbox. (4 columns)
    When I double click on a line, I want the value of this rule and the second column in the textbox6 of UserForm1 is put down

    I use the following code
    Please Login or Register  to view this content.

    Please Login or Register  to view this content.
    Regards,

    Dirk
    cross-posting
    http://www.mrexcel.com/forum/showthread.php?t=570409


    Dirk.
    Last edited by Dirk55; 08-09-2011 at 02:30 PM.

  2. #2
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS365 Family 64-bit
    Posts
    24,675

    Re: By a double click in listbox, a textbox to fill another UserForm

    There is no built-in double-click event for a listbox. It is more of an industry standard to add an "OK" button below the listbox to press when the user has made a selection.

    I do not understand this:
    I want the value of this rule and the second column in the textbox6 of UserForm1 is put down
    I don't know what "this rule" means. Do you mean that you want the value in the second column of the selected row of the listbox to be copied to textbox6 in UserForm1?
    Last edited by 6StringJazzer; 08-09-2011 at 03:25 PM. Reason: deleted reference to handling generic double-click event--it referred to C# code, not VBA
    Jeff
    | | |會 |會 |會 |會 | |:| | |會 |會
    Read the rules
    Use code tags to [code]enclose your code![/code]

  3. #3
    Registered User
    Join Date
    08-09-2011
    Location
    Arnhem, NL
    MS-Off Ver
    Excel 2007
    Posts
    3

    Re: By a double click in listbox, a textbox to fill another UserForm

    Quote Originally Posted by 6StringJazzer View Post
    There is no built-in double-click event for a listbox. It is more of an industry standard to add an "OK" button below the listbox to press when the user has made a selection.

    I do not understand this:
    I don't know what "this rule" means. Do you mean that you want the value in the second column of the selected row of the listbox to be copied to textbox6 in UserForm1?

    Yes, I mean this


    Regards,

    dirk

  4. #4
    Registered User
    Join Date
    08-09-2011
    Location
    Arnhem, NL
    MS-Off Ver
    Excel 2007
    Posts
    3

    Re: By a double click in listbox, a textbox to fill another UserForm

    an example
    Attached Files Attached Files

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1