+ Reply to Thread
Results 1 to 6 of 6

Problem with listview click event.

  1. #1
    Registered User
    Join Date
    09-21-2012
    Location
    India
    MS-Off Ver
    Excel 2010
    Posts
    61

    Problem with listview click event.

    Hi,

    I have a userform in which user can select multiple criteria and the final result is displayed in a Listview. Everything is working fine. I use Access as the database. For some records, some fields are blank. For that 'Not Available' is displayed.
    Problem is when the select criteria returns a record which having all the fields as 'Not Available' (which is displaying correctly in Listview), when user clicks on this item i'm getting error message 'Run Time Error 13 Type Mismatch'. Only the first field is in 'Number' data type. Completed my project almost but unable to submit due to this error. Below is my code:
    Please Login or Register  to view this content.

    Kindly have a look and plz help me out. Thanks in advance.

  2. #2
    Forum Guru JosephP's Avatar
    Join Date
    03-27-2012
    Location
    Ut
    MS-Off Ver
    2003/10
    Posts
    7,328

    Re: Problem with listview click event.

    which line causes the error?
    Josie

    if at first you don't succeed try doing it the way your wife told you to

  3. #3
    Registered User
    Join Date
    09-21-2012
    Location
    India
    MS-Off Ver
    Excel 2010
    Posts
    61

    Re: Problem with listview click event.

    If Me.ListView1.SelectedItem >= 0 Then

    in the listview click event

  4. #4
    Forum Guru JosephP's Avatar
    Join Date
    03-27-2012
    Location
    Ut
    MS-Off Ver
    2003/10
    Posts
    7,328

    Re: Problem with listview click event.

    perhaps just change it to
    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    09-21-2012
    Location
    India
    MS-Off Ver
    Excel 2010
    Posts
    61

    Re: Problem with listview click event.

    Hi JosephP,

    Its working.
    Thanks a ton.

    Regards,
    Kiran2012

  6. #6
    Forum Guru JosephP's Avatar
    Join Date
    03-27-2012
    Location
    Ut
    MS-Off Ver
    2003/10
    Posts
    7,328

    Re: Problem with listview click event.

    you're welcome

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


    New quick method:
    Select Thread Tools-> Mark thread as Solved. To undo, select Thread Tools-> Mark thread as Unsolved.

    Or you can use this way:

    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