PDA

Click to See Complete Forum and Search --> : HOW TO -tree view from scratch !!!


lirlir
Jul 12th, 2000, 06:43 AM
is it possible building a tree view from scratch,
without an ActiveX.

msdnexpert
Jul 12th, 2000, 08:08 AM
Hi lirlir,
Yes it is very much possible to have a tree view by just coding in HTML and ASP without using the OCX, but the code is pretty cumbersome.
msdnexpert

lirlir
Jul 12th, 2000, 08:22 AM
hi msdnexpert,

well u c i m trying 2 build a treeview that can be visible
in both Netscape & IE.
do u have any idea how to do so. (code,sample,example,link...)

it ll b very helpfull if u would.

thanks lirlir

capone
Jul 12th, 2000, 09:15 AM
Here's some code that works for me without ActiveX:
<SCRIPT language="JavaScript">
<!--
//Creates folding tree effect
var head="display:''"
function doit(header)
{
var head=header.style
if (head.display=="none")
head.display=""
else
head.display="none"
}
//-->
</SCRIPT>
Then add your headers, I use:
<H4 style="cursor:hand" onClick="doit(document.all[this.sourceIndex+1])">Header</H4>
Then put this:
<SPAN style="display:none" style=&{head};>
'Enter stuff you want hidden till someone clicks the header
</SPAN>

Hope this is what you were looking for.

lirlir
Jul 12th, 2000, 09:45 AM
hi capone,

Thanks, but there r few problems with this code :
1. its allowing only one node
2. its doesnt work on NS.

i ll try to set it up , if u ll have success on your side
please share it with me.

lirlir

Ianpbaker
Jul 12th, 2000, 11:02 AM
I have found this site that uses a propper treeview just using Javascript but the code is pretty big

http://www.jsh.de/treeview/index.htm#href=treeview.htm

Ian

lirlir
Jul 13th, 2000, 01:08 AM
Ian

U realy R the GURU of them all.

thanks a lot (again)

lirlir.