Click here to Skip to main content
15,895,656 members
Articles / Desktop Programming / Windows Forms

MS Access Databases Queries Editor

Rate me:
Please Sign up or sign in to vote.
4.91/5 (23 votes)
26 Jul 2009GPL38 min read 152.7K   9.5K   116  
A very productive, easy to use tool to edit your Sql Queries against MS Access Databases
Imports System.ComponentModel

<ToolboxBitmap(GetType(System.Windows.Forms.TreeView))> _
Public Class DevTreeView
    Inherits TreeView

#Region "LastUsedNode  Stuff"
    ''' <summary>
    ''' this will be used with context menu that deals with each nodes 
    ''' when it opens (the context menue I mean) which node will be affected ?......
    ''' this field will determain this node......
    ''' and its value will be set by seviral events of the TreeView
    ''' </summary>
    Private _LastUsedNode As TreeNode

    ''' <summary>
    ''' this will be used with context menu that deals with each nodes 
    ''' when it opens (the context menue I mean) which node will be affected ?......
    ''' this Property will determain this node......
    ''' </summary>
    <Browsable(False)> _
    Public ReadOnly Property LastUsedNode() As TreeNode
        Get
            Return _LastUsedNode
        End Get
    End Property

    Protected Overrides Sub OnAfterCheck(ByVal e As System.Windows.Forms.TreeViewEventArgs)
        MyBase.OnAfterCheck(e)
        _LastUsedNode = e.Node
    End Sub

    Protected Overrides Sub OnMouseDown(ByVal e As System.Windows.Forms.MouseEventArgs)

        Dim CursorPos = New Point(e.X, e.Y)
        _LastUsedNode = Me.HitTest(CursorPos).Node
    End Sub

#End Region

End Class

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The GNU General Public License (GPLv3)


Written By
Software Developer
Syrian Arab Republic Syrian Arab Republic
The more I learn the more I see my ignorance.

Comments and Discussions