breadcrumb trail in vbscript

Posted on 2009-04-17
Last Modified: 2012-05-06
I need some VBScript code to output a breadcrumb trail assuming were in the section Press Releases of a table called "test1". This table has got a column named "Section".
Question by:JDandLarLar
    LVL 6

    Accepted Solution

    Play around with this little function:
    function getTrails(ByVal intId)
    	set objRS = server.createobject("adodb.recordset")
    	intCurId = intId
    	do until intCurId = 0
    		if isnumeric(intCurId) then
   "SELECT Section,ParentID FROM test1 WHERE Id="&intCurId&"",con
    			if not objRS.eof then
    				intCurId = objRS("ParentID")
    				strTrail = strTrail & objRS("Section") & ","
    			end if
    			intCurId = 0
    		end if
    	set objRS = nothing
    	getTrails = strTrail
    end function

    Open in new window


    Author Closing Comment


    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Highfive + Dolby Voice = No More Audio Complaints!

    Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

    I recently decide that I needed a way to make my pages scream on the net.   While searching around how I can accomplish this I stumbled across a great article that stated "minimize the server requests." I got to thinking, hey, I use more than one…
    This demonstration started out as a follow up to some recently posted questions on the subject of logging in: and…
    how to add IIS SMTP to handle application/Scanner relays into office 365.
    In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

    759 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    13 Experts available now in Live!

    Get 1:1 Help Now