Click here to Skip to main content
15,894,017 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: Cannot update or delete access database Pin
dan!sh 18-Mar-09 19:32
professional dan!sh 18-Mar-09 19:32 
AnswerRe: Cannot update or delete access database Pin
_Damian S_18-Mar-09 19:55
professional_Damian S_18-Mar-09 19:55 
GeneralRe: Cannot update or delete access database [modified] Pin
hendrikbez18-Mar-09 20:03
hendrikbez18-Mar-09 20:03 
GeneralRe: Cannot update or delete access database Pin
Christian Graus18-Mar-09 20:59
protectorChristian Graus18-Mar-09 20:59 
GeneralRe: Cannot update or delete access database Pin
hendrikbez18-Mar-09 21:07
hendrikbez18-Mar-09 21:07 
GeneralRe: Cannot update or delete access database Pin
Christian Graus18-Mar-09 21:40
protectorChristian Graus18-Mar-09 21:40 
GeneralRe: Cannot update or delete access database Pin
Christian Graus18-Mar-09 22:18
protectorChristian Graus18-Mar-09 22:18 
QuestionHow could you perform a recursive call for a treeview for two different actions? Pin
JUNEYT18-Mar-09 12:11
JUNEYT18-Mar-09 12:11 
Hi,

I have a treeview within directories of all drives including checkboxes (Netframework 2.0) When I check one node the following procedure below checks all the childs of the checked node. Therefore I have called the procedure inside the Treeview1_AfterCheck event procedure. But my aim is also to also check the node which is tagged with a driver name such as (C:\, D:\ maybe E:\ or something else). When I do that I am getting stackoverflow error because of recursive calls. How could you perform both actions at once to check the main node (driver name) and the nodes under the other checked one? Somehow I have to get rid of CheckRootNode procedure. Any sample code will be appreciated.

Thanks.

'
'This procedure checks the root node of any child under it
'
Private Sub CheckRootNode(ByVal GetNode As TreeNode)

    Do While Not GetNode.Parent Is Nothing

        Root = GetNode.Parent
        CheckRootNode(Root)
    Loop

    TreeView1.Nodes(Root.Index).Checked = True
End Sub

'
'This procedure checks all the child nodes of the parent
'
Private Sub CheckChildNodes(ByVal GetParentNode As TreeNode, ByVal CheckState As Boolean)

    For Each xnode As TreeNode In GetParentNode.Nodes
        xnode.Checked = CheckState
    Next

End Sub



Private Sub TreeView1_AfterCheck(ByVal sender As Object, ByVal e As System.Windows.Forms.TreeViewEventArgs) Handles TreeView1.AfterCheck

        Call CheckChildNodes(e.Node, e.Node.Checked)
        Call CheckRootNode(e.Node)
End Sub


What a curious mind needs to discover knowledge is noting else than a pin-hole.


AnswerRe: How could you perform a recursive call for a treeview for two different actions? Pin
Christian Graus18-Mar-09 12:43
protectorChristian Graus18-Mar-09 12:43 
Questionopen file directory Pin
captainmogo18-Mar-09 7:06
captainmogo18-Mar-09 7:06 
AnswerRe: open file directory Pin
iamalik18-Mar-09 7:26
professionaliamalik18-Mar-09 7:26 
GeneralRe: open file directory Pin
captainmogo18-Mar-09 7:52
captainmogo18-Mar-09 7:52 
GeneralRe: open file directory Pin
iamalik18-Mar-09 8:03
professionaliamalik18-Mar-09 8:03 
GeneralRe: open file directory Pin
captainmogo18-Mar-09 8:17
captainmogo18-Mar-09 8:17 
GeneralRe: open file directory Pin
iamalik18-Mar-09 8:36
professionaliamalik18-Mar-09 8:36 
GeneralRe: open file directory Pin
tech60318-Mar-09 14:56
tech60318-Mar-09 14:56 
AnswerRe: open file directory Pin
Luc Pattyn18-Mar-09 8:31
sitebuilderLuc Pattyn18-Mar-09 8:31 
GeneralRe: open file directory Pin
captainmogo18-Mar-09 8:39
captainmogo18-Mar-09 8:39 
AnswerRe: open file directory [modified] Pin
Alan N18-Mar-09 8:54
Alan N18-Mar-09 8:54 
GeneralRe: open file directory Pin
captainmogo18-Mar-09 9:04
captainmogo18-Mar-09 9:04 
GeneralRe: open file directory [modified] Pin
Alan N18-Mar-09 9:27
Alan N18-Mar-09 9:27 
GeneralRe: open file directory Pin
captainmogo19-Mar-09 3:28
captainmogo19-Mar-09 3:28 
Questioncalling a menu form from another menu Pin
Member 462416918-Mar-09 7:04
Member 462416918-Mar-09 7:04 
AnswerRe: calling a menu form from another menu Pin
iamalik18-Mar-09 7:38
professionaliamalik18-Mar-09 7:38 
GeneralRe: calling a menu form from another menu Pin
0x3c018-Mar-09 8:21
0x3c018-Mar-09 8:21 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.