Solved

Finding a control inside listview

Posted on 2012-12-30
1
396 Views
Last Modified: 2012-12-31
I have a listview like this:

<asp:ListView ID="lvSubscription" 
 ....
    <ItemTemplate>
         <td style="text-align:center" width="295" >
             [b] <telerik:RadTreeView ID="RadTreeView1"  runat="server">
               
              </telerik:RadTreeView>[/b]
          </td>
    </ItemTemplate>
</asp:ListView>

Open in new window


How can I find that listview when in page_load? This gives me null. Is this because when the page loads, the listview is not created yet??

  if (!Page.IsPostBack)
     RadTreeView tv = (RadTreeView)lvSubscription.FindControl("RadTreeView1");

Open in new window

0
Comment
Question by:Camillia
1 Comment
 
LVL 39

Accepted Solution

by:
Pratima Pharande earned 500 total points
ID: 38731944
0

Featured Post

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

ASP.Net to Oracle Connectivity Recently I had to develop an ASP.NET application connecting to an Oracle database.As I am doing it first time ,I had to solve several problems. This article will help to such developers  to develop an ASP.NET client…
The article shows the basic steps of integrating an HTML theme template into an ASP.NET MVC project
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…

770 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