Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Visual Basic
  4. How to hide frame when clicking on white area of listview where there is no data?

How to hide frame when clicking on white area of listview where there is no data?

Scheduled Pinned Locked Moved Visual Basic
tutorialquestion
1 Posts 1 Posters 3 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    method007
    wrote on last edited by
    #1

    I have frame and listview1. I want to hide the frame when i click(left click or right click) on white area of listview1 where is there is no data (As shown in attched pic).could any one show me how this can be done?Thanks Private Sub ListView1_Click() gstrSomething = ListView1.SelectedItem.SubItems(4) gstrSomethingElse = ListView1.SelectedItem.Text Frame1.Visible = True End Sub Private Sub ListView1_MouseDown(Button As Integer, Shift As Integer, x As Single, y As Single) Dim lvwItem As ListItem If Button = vbRightButton Then Set lvwItem = ListView1.HitTest(x, y) If Not lvwItem Is Nothing Then Frame1.Visible = True lvwItem.Selected = True PopupMenu mnuEdit Else Frame1.Visible = False End If End If End Sub

    1 Reply Last reply
    0
    Reply
    • Reply as topic
    Log in to reply
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes


    • Login

    • Don't have an account? Register

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • World
    • Users
    • Groups