Click here to Skip to main content
11,408,708 members (60,601 online)
Click here to Skip to main content

A Tree Control using ASP

, 15 May 2000
Rate this:
Please Sign up or sign in to vote.
A simple tree control written using ASP that allows you to display hierachical data.
  • Download source files - 16 Kb
  • Sample Image - TreeControl.jpg

    The project is a simple Tree Control created using ASP. This is first version that offers only display feature, but in the next version the user will be able to add, edit and delete nodes.

    The Tree Control structure is stored in an access database. The TreeContent table has following columns:

  • IDNode – number, is the node ID and it not be duplicated.
  • IDParentNode – number, is the ID parent node.
  • NodeCaption – string, node caption that will be displayed in the page.
  • NodeType – string, is type of node. Can be one from two valid values: F – folder, I – item. If it contains another value then the node will be folder (F).
  • NodeAction – string, is node action. Is available only for items node, if the node is folder then it has only one action – expand tree. i.e. for node action:, javascript:alert("Test"),
  • The Tree Control can be expanded only to one branch. So, you must modify the path for the database or create a DNS for database connection in the TreeWork.asp file:

     // ' Here YOU MUST change the database path, or create a DSN
     // Const cstrConnectionString = "DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=D:\Iulian\TestTree\testtree.mdb"

    Thanks again and enjoy ...


    This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

    A list of licenses authors might use can be found here


    About the Author

    Iulian Iuga
    Web Developer
    Germany Germany
    No Biography provided

    Comments and Discussions

    GeneralMulti-Column TreeView PinmemberJim Brooks3-Nov-07 11:47 
    Generalreply immediately my mail Pinmemberlingeswararaj.s3-Dec-06 23:46 
    GeneralA Tree Control using ASP Pinmemberodiebaby15-Mar-06 20:33 
    GeneralPretty good! Pinmemberdeepakjha13-Jan-05 2:48 
    GeneralRe: Pretty good! Pinmemberanu_dreams9-Jun-05 4:48 
    GeneralRe: Pretty good! Pinmembervickyvinod117-Dec-09 21:10 
    GeneralError Message Pinmemberacpt15-Dec-04 19:41 
    GeneralRe: Error Message PinmemberIulian Iuga7-Jan-05 2:13 
    GeneralRe: Error Message Pinmemberanu_dreams9-Jun-05 4:50 
    GeneralRe: Error Message PinmemberMember 889484930-Apr-12 2:39 
    QuestionHow to create a tree with infinite no of child Pinmemberpercyvimal18-Mar-04 0:30 
    Generalcode does not work Pinmemberramyamn30-Dec-03 0:22 
    GeneralExcellent control PinmemberAveryH13-Nov-03 23:54 
    GeneralError, general error. Watch the code! (1.5) PinmemberIulian Iuga3-Nov-03 8:42 
    GeneralRe: Error, general error. Watch the code! (1.5) Pinmemberpercyvimal11-Mar-04 17:56 
    Generalyour code is not work PinmemberHimadrish Laha23-Sep-03 2:07 
    GeneralError, general error. Pinmemberchungwong16-Jun-03 10:43 
    GeneralRe: Error, general error. PinmemberIulian Iuga16-Jun-03 21:37 
    GeneralTree should remain always expanded Pinsussvinod (India)29-May-03 0:12 
    GeneralError Page PinsussAnonymous18-Dec-02 19:48 
    GeneralRe: Error Page PinmemberIulian Iuga18-Dec-02 22:43 
    GeneralRe: Error Page Pinmembershekhar_shah200030-Jan-03 7:15 
    Generaliam also getting the same error 1.5 please help Pinmemberrahil18-Aug-03 10:42 
    GeneralRe: iam also getting the same error 1.5 please help PinmemberIulian Iuga1-Sep-03 2:45 
    Please give me more information about the environment in which you are running in problems? (OS? IIS version? Office version?) Thanks.
    Generaliam also getting the same error 1.5 please help Pinmemberemmanuelconstant22-Oct-03 7:15 
    GeneralRe: iam also getting the same error 1.5 please help Pinsussbunso24-Oct-03 15:00 
    Generaltfrtrt PinsussAnonymous4-Dec-02 21:01 
    Generaltfrtrt PinsussAnonymous4-Dec-02 20:35 
    Generaltree control in debug watch window PinmemberPawanonly5-May-02 20:32 
    GeneralRe: tree control in debug watch window PinmemberIulian Iuga10-May-02 2:38 
    GeneralASP tree view PinmemberAnonymous17-Apr-02 22:15 
    GeneralRe: ASP tree view PinsussAnonymous26-Aug-02 11:43 
    GeneralRe: ASP tree view PinsussAnonymous28-Oct-02 21:20 
    GeneralRe: ASP tree view Pinmemberngocha7-Apr-04 19:20 
    QuestionIt is possible to have Action on folder level? Pinmemberjezmun5-Apr-02 0:06 
    GeneralMuito legal PinmemberAnonymous5-Oct-01 9:12 
    Questioncan i get the parent item value from the selected item? Pinmembervicky6-May-01 19:43 
    QuestionCan many branches be expanded at a time? PinmemberMohit25-Apr-01 6:01 
    AnswerRe: Can many branches be expanded at a time? PinmemberAnonymous18-Jun-01 0:02 
    GeneralAdjustable Frames(Urgent) PinsussGopal19-Aug-00 1:12 
    GeneralRe: Adjustable Frames(Urgent) PinmemberManu22-Dec-00 16:17 
    GeneralRe: Adjustable Frames(Urgent) PinmemberAnonymous6-Apr-01 11:10 
    Generallklkkkk PinmemberAnonymous10-Apr-02 22:10 
    GeneralRe: Adjustable Frames(Urgent) PinsussAnonymous4-Dec-02 23:47 
    GeneralTreeItem PinsussMike Rosapepe23-May-00 5:03 

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

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

    | Advertise | Privacy | Terms of Use | Mobile
    Web02 | 2.8.150414.5 | Last Updated 16 May 2000
    Article Copyright 2000 by Iulian Iuga
    Everything else Copyright © CodeProject, 1999-2015
    Layout: fixed | fluid