Treeview in asp.net 2.0

T

tmldias

Hi all,

I've already "lost" too many time and no success...

I want to remove the default postback when the user presses a node in
the tree. I want to navigate and selecte nodes in the tree just
client-side without postbacks to the server.

Thanks.
 
D

Dave Johnson

Greetings,

after you downlaod the atals framework u can simply add this part of
code in your aspx page in your "VS Atlas project" just right after the
script manager code



<atlas:UpdatePanel ID="up1" runat="server">
<ContentTemplate>
<atlas:UpdateProgress ID="process1" runat="server">
<ProgressTemplate>
// Code for your TreeView goes here

</ProgressTemplate>
</atlas:UpdateProgress>
</Content Templat>
</Atlas:updatepanel>


its tht simple, happy coding ;)

Sharing makes All the Difference
 
D

Dave Johnson

i was about to forget to refer to the updateprogress control in the
atlas framework i think u gonna like this so let me add this 2 lines of
code.

<atlas:ScriptManager ID="sm1" runat="server"
EnablePartialRendering="true"></atlas:ScriptManager>
<atlas:UpdatePanel ID="up1" runat="server">
<ContentTemplate>


<atlas:UpdateProgress ID="process1" runat="server">
<ProgressTemplate>
<div class="title" style="font-weight: bold;
vertical-align: middle; text-transform: capitalize;
color: #cc6600; font-family: 'Arial Narrow', 'Arial
Black'; letter-spacing: 10px;
text-align: center">
<img alt="" src="../loading.gif" style="width: 55px;
height: 55px" /><br />
<br />
Loading</div>
</ProgressTemplate>
</atlas:UpdateProgress>



</ContentTemplate>
</atlas:UpdatePanel>


ofcourse u gonna need a cool loading.gif just goo google images search
for loading.gif u will find some cool stuff pick one and after adding
the updateprogress control with your treeview control inside the update
panel u will have dymanic client-side tree control with some cool
loading styles ;) i love atlas ;)

Sharing makes All the Difference
 
T

Teemu Keiski

Hi,

About populating without postback
http://aspalliance.com/732

About playing with SelectAction
http://aspadvice.com/blogs/joteke/archive/2006/08/19/20948.aspx

About modifying selection, you set node's SelectAction. Just note that
TreeView's nodes work in two mutually exclusive mode, selection mode or
navigation mode. Node is in navigation mode, if it has NavigateUrl
specified. And it's in selection mode when NavigateUrl equals to empty
string. In selection mode you can control how it works, via the SelectAction
property.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top