1. We have moved from vBulletin to XenForo and you are viewing the site in the middle of the move. Though the functional aspect of everything is working fine, we are still working on other changes including the new design on Xenforo.
    Dismiss Notice

vbscript function to add items from a treeview node to a listbox

Discussion in 'Web Design, HTML And CSS Forums' started by sans123, Aug 17, 2007.

  1. sans123

    sans123 New Member

    Joined:
    Aug 17, 2007
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    0
    Below is the vbscript function.
    I want to display all the items selected from the node(SelectedNode) inside the listbox(lstMultipleFileUpload)which is inside a div tag in the HTML page

    Code:
    <script language="vbscript" for="FileListTreeView" event="oncheck">
    Dim SelectedNode	
    Dim str
    Set SelectedNode = FileListTreeView.getTreeNode(window.event.TreeNodeIndex)			
    str = "" & document.all.item("lstMultipleFileUpload").innerHTML					
    If (SelectedNode.getAttribute("Checked") ) Then
    str = str & "<DIV class=list>&nbsp;" & SelectedNode.getAttribute("id") & "</DIV>"
    Else
    str = Replace(str,"<DIV class=list>&nbsp;" & SelectedNode.getAttribute("id") & "</DIV>","")
    End If
    document.all.item("lstMultipleFileUpload").innerHTML= "" & str			
    </script>
     
    Last edited by a moderator: Aug 17, 2007
  2. pradeep

    pradeep Team Leader

    Joined:
    Apr 4, 2005
    Messages:
    1,646
    Likes Received:
    86
    Trophy Points:
    0
    Occupation:
    Programmer
    Location:
    Kolkata, India
    Home Page:
    What is error you are facing??
     

Share This Page