Can I use NodeFactory to get the root directory? Options
ChanceUSC
Posted: Sunday, January 13, 2008 7:47:03 PM
Rank: Newbie

Joined: 12/30/2007
Posts: 6
Is it possible for me to use the NodeFactory to reach the root level.. for instance can I do something along the lines of:
Node root = new Node("Content");

Thanks,
Chance
mortenbock
Posted: Sunday, January 13, 2008 11:39:07 PM

Rank: Addict

Joined: 7/19/2006
Posts: 739
Location: Århus, Denmark
Chance wrote:

Is it possible for me to use the NodeFactory to reach the root level.. for instance can I do something along the lines of:
Node root = new Node("Content");

Thanks,
Chance


I think the root node always has an ID of -1. So you should be able to do this:

Code:

Node root = new Node(-1);


But I haven't tested it...

Morten Bock - Level 2 certified - MVP 2008/2009 - My danish blog with a few english posts

Users browsing this topic
Guest


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.