+ Reply to Thread
Results 1 to 8 of 8

Double clicking the results in Listview to bring up another userform

  1. #1
    Registered User
    Join Date
    03-07-2011
    Location
    Richmond BC
    MS-Off Ver
    Excel 2003
    Posts
    4

    Arrow Double clicking the results in Listview to bring up another userform

    Hi everyone,

    I am very new to VBA and definitely consider myself a beginner in regards to VBA. From these forums I have managed to create a listview to show search results for my database.

    I thank everyone who has contributed in these forums. You guys/girls have made life a lot easier

    I am stuck with one last thing I need to do for my project. I hope someone can help me out.

    I created a listview for my search results and what I am trying to do is from my listview results I want to be able to double click a row of data (results) to bring up that specific row of data in another userform so the results can be shown in a more organized look. Results showing in textboxes. I hope I am making sense and I hope this is possible.

    Thank you in advance

  2. #2
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: Double clicking the results in Listview to bring up another userform

    To best describe or illustrate your problem you would be better off attaching a dummy workbook, the workbook should contain the same structure and some dummy data of the same type as the type you have in your real workbook - so, if a cell contains numbers & letters in this format abc-123 then that should be reflected in the dummy workbook.

    If needed supply a before and after sheet in the workbook so the person helping you can see what you are trying to achieve.

    Doing this will ensure you get the result you need!
    Hope that helps.

    RoyUK
    --------
    For Excel Tips & Solutions, free examples and tutorials why not check out my web site

    Free DataBaseForm example

  3. #3
    Registered User
    Join Date
    03-07-2011
    Location
    Richmond BC
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Double clicking the results in Listview to bring up another userform

    Thanks Roy.

    Attached is my dummy workbook.

    There are three userforms. One userform is to add data. One is to search using listview to show the results. The third userform (frmresult) I am hoping to show the data from the listview. The third userform looks exactly like the one to add the data.

    I am able to bring the third userform by doubleclicking the results in the listview but with no actual data. That is the part where I am stuck. Any advice would be greatly appreciated.
    Last edited by vbanew; 03-21-2011 at 12:18 PM.

  4. #4
    Registered User
    Join Date
    03-07-2011
    Location
    Richmond BC
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Double clicking the results in Listview to bring up another userform

    Bump Bump Bump =)

  5. #5
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: Double clicking the results in Listview to bring up another userform

    Personally I wouldn't use such a control as other users might not have access to it.

    I would suggest that you look at a ListBox control, that's what I always use & have posted examples on the Forum

  6. #6
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258

    Re: Double clicking the results in Listview to bring up another userform

    Hello vbanew,

    Here is the code for the ListView control to load the Result form..
    Please Login or Register  to view this content.
    Sincerely,
    Leith Ross

    Remember To Do the Following....

    1. Use code tags. Place [CODE] before the first line of code and [/CODE] after the last line of code.
    2. Thank those who have helped you by clicking the Star below the post.
    3. Please mark your post [SOLVED] if it has been answered satisfactorily.


    Old Scottish Proverb...
    Luathaid gu deanamh maille! (Rushing causes delays!)

  7. #7
    Registered User
    Join Date
    03-07-2011
    Location
    Richmond BC
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Double clicking the results in Listview to bring up another userform

    Thanks Leith and Roy for all the help not only in this thread but all the others I've been learning from!!

    You guys are awesome

    It must have been a long day at work. But how do you mark this as Solved?

  8. #8
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: Double clicking the results in Listview to bring up another userform

    If you are satisfied with the solution(s) provided, please mark your thread as Solved.

    How to mark a thread Solved
    Go to the first post
    Click edit
    Click Go Advanced
    Just below the word Title you will see a dropdown with the word No prefix.
    Change to Solved
    Click Save

+ 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