| | |
[HELP] Please Check this thread its urgent!
Please support our VB.NET advertiser: $4.95 a Month - ASP.NET Web Hosting – Click Here!
![]() |
•
•
Join Date: Sep 2008
Posts: 36
Reputation:
Solved Threads: 0
Hello all, i have a problem and im in need of your help... I have a treeview with 2 parent Nodes and in the parent nodes there are some node:
In all nodes there is a checkbox for a spesific reason, like this:
What i want to do is to insert all the info that the treeview has into a Access Database. I can insert all the child nodes of the treeview into the db but i cant insert the Parent Nodes
Here are the funtions that i use to add the child nodes:
1.
2.
Red = Function that is not included.
WHAT I WANT TO DO IS TO CHANGE SOMETHING SO AS TO INSERT INTO THE DATABASE ALL THE TREE(PARENT AND CHILD).... PLZ ANY CHANGES MADE PLZ MARK THEM WITH RED COLOR SO I CAN UNDERSTAND WHAT HAVE I DONE WRONG...
PS: Answer as soon as possible, as the title says "It is Urgent!!!"
Members
New
Search
Administration
Groups
Photo LocationIn all nodes there is a checkbox for a spesific reason, like this:
(checkbox) Members (checkbox) New (checkbox) Search (checkbox) Administration (checkbox) Groups (checkbox) Photo Location
What i want to do is to insert all the info that the treeview has into a Access Database. I can insert all the child nodes of the treeview into the db but i cant insert the Parent Nodes
Here are the funtions that i use to add the child nodes:
1.
VB.NET Syntax (Toggle Plain Text)
Private Sub SaveTree(ByRef Treeview As Telerik.WinControls.UI.RadTreeView) For Each Node As Telerik.WinControls.UI.RadTreeNode In Treeview.Nodes SaveNode(Node) Next End Sub
2.
Red = Function that is not included.
Private Sub SaveNode(ByRef TreeNode As Telerik.WinControls.UI.RadTreeNode)
Dim con As New OleDbConnection
Dim command As New OleDbCommand
Dim trans As OleDbTransaction = Nothing
Dim RightID As Integer
Dim GroupID As Integer
Dim InsertString As String
GroupID = functions.GetInfo(connstring, "SELECT ID FROM Groups WHERE GroupName = '" & cmbProperty.Text & "'", "Group", "ID")
RightID = functions.GetNextVal(connstring, "Right")
functions.InsertWithoutMessage(con, connstring, trans, command, "INSERT INTO Rights(ID,RightName) VALUES(" & RightID & ",'" & txtRightName.Text & "')")
For Each Node As Telerik.WinControls.UI.RadTreeNode In trvForms.Nodes 'TreeNode.Nodes
InsertString = "INSERT INTO Group_Right_Forms(Group_ID,Right_ID,Form_ID,ShowRight,InsertRight,UpdateRight,DeleteRight) VALUES(" & GroupID & "," & RightID & "," & Node.Tag & "," & Node.Checked.ToString() & "," & GetPanel(Node.Tag).InsertCheck.Checked.ToString() & "," & GetPanel(Node.Tag).UpdateCheck.Checked.ToString() & "," & GetPanel(Node.Tag).DeleteCheck.Checked.ToString() & ")"
functions.InsertWithoutMessage(con, connstring, trans, command, InsertString)
For Each Child As Telerik.WinControls.UI.RadTreeNode In Node.Nodes
SaveNode(Child)
Next
Next
End SubWHAT I WANT TO DO IS TO CHANGE SOMETHING SO AS TO INSERT INTO THE DATABASE ALL THE TREE(PARENT AND CHILD).... PLZ ANY CHANGES MADE PLZ MARK THEM WITH RED COLOR SO I CAN UNDERSTAND WHAT HAVE I DONE WRONG...

PS: Answer as soon as possible, as the title says "It is Urgent!!!"
![]() |
Similar Threads
- Regarding Database-Reply early-Urgent (Visual Basic 4 / 5 / 6)
- Javaprogrammers and other talents (Software Development Job Offers)
- threads urgent (Java)
- Urgent help in this code plz (C++)
- URGENT! Loading Roles From ticket.UserData (ASP.NET)
- Urgent!!! Multiple IE windows on startup (Web Browsers)
- i really need help..urgent (Windows NT / 2000 / XP)
- Add/Remove Programs List Gone! (Windows 95 / 98 / Me)
Other Threads in the VB.NET Forum
- Previous Thread: AttachEventHandler issues
- Next Thread: How to create file in VB.net (VS 2005)
| Thread Tools | Search this Thread |
"crystal .net .net2005 .net2008 30minutes 2005 2008 access account arithmetic array basic button buttons center check code component connectionstring convert crystalreport data database databasesearch datagrid datagridview date design dissertation dissertations dissertationthesis dosconsolevb.net dropdownlist excel fade file-dialog filter firewall folder ftp generatetags hardcopy image images input insert intel math monitor navigate net networking opacity output panel passingparameters peertopeervideostreaming picturebox picturebox1 port printing problem problemwithinstallation project reports" savedialog searchvb.net select shutdown string survey tcp temperature text textbox timer timespan toolbox trim updown user useraccounts usercontrol vb vb.net vb.netcode vb.netformclosing()eventpictureboxmessagebox vb.nettoolboxvisualbasic2008sidebar vb2008 vbnet view visual visualbasic visualbasic.net visualstudio visualstudio2008 web winforms wpf year






