Looks like i fixed that too, just by changing my delete code to the following:
I also obviously added a warning button as well.. if someone can help me with a way to edit these entries I would appreciate it. I realize this is all pretty basic, and it may seem 'beneath you' to respond, but I would greatly appreciate it..Code:Sub DeleteHosts(ByVal position As Integer) Dim iResponse As Integer iResponse = MsgBox("Are you sure you want to delete the session?", vbYesNo, "Confirm Session Delete") If iResponse = vbYes Then Dim delnode As XmlNode = xmldoc.SelectSingleNode( _ "/Sessionlist/session[" & position & "]") Dim root As XmlNode = xmldoc.DocumentElement root.RemoveChild(delnode) xmldoc.Save("c:\sessionlist.xml") Else Return End If




Reply With Quote