Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
123 views
I have set up a treeview / grid combo and I am trying to set a folder icon for each node. Basically I am aiming for the Outlook 2010 look, but just can't recreate it even with the example.

My folders appear underneath the +/- symbols and the tree structure goes crazy and is no longer neatly nested but more like stepped.

What have I done wrong?

Thanks


<telerik:RadSplitter ID="rdSplitter" runat="server" Height="800px"
    Width="623px" BorderSize="1" BorderStyle="None" Skin="Windows7">
    <telerik:RadPane ID="rdTreeViewPane" runat="server" Height="500px" Width="295px">
        <telerik:RadTreeView ID="rdTreeView" Runat="server"
            onnodeclick="rdTreeView_NodeClick" Width="100%" Height="100%" Skin="Windows7">
        </telerik:RadTreeView>
    </telerik:RadPane>
 
    <telerik:RadSplitBar ID="RadSplitBar1" runat="server" />
 
    <telerik:RadPane ID="rdGridViewPane" runat="server" Width="330px">
        <telerik:RadGrid ID="rdViewDocuments" runat="server" GridLines="None"
            Width="99.5%" AllowPaging="True" Skin="Windows7" PageSize="20">
            <MasterTableView AutoGenerateColumns="False" DataKeyNames="DocumentID">
            <RowIndicatorColumn>
                <HeaderStyle Width="20px"></HeaderStyle>
            </RowIndicatorColumn>
            <ExpandCollapseColumn>
                <HeaderStyle Width="20px"></HeaderStyle>
            </ExpandCollapseColumn>
                <Columns>
                    <telerik:GridImageColumn DataImageUrlFields="FileType" DataImageUrlFormatString="~/images/icons/{0}.png"
                        ImageHeight="12px" ImageWidth="12px" UniqueName="column6" AllowFiltering="False"
                        AllowSorting="False" DataAlternateTextField="FileType">
                        <ItemStyle Width="22px" Height="22px" VerticalAlign="Middle" HorizontalAlign="Center" />
                    </telerik:GridImageColumn>
 
                    <telerik:GridTemplateColumn DataField="Title" HeaderText="Title" UniqueName="column3">
                        <ItemTemplate>
                            <asp:HyperLink runat="server" ID="DownloadLink" NavigateUrl='<%# DataBinder.Eval(Container, "DataItem.FilePath", "{0}") %>'
                                Text='<%# DataBinder.Eval(Container, "DataItem.Title") %>' Target="_blank"></asp:HyperLink>
 
                            <telerik:RadToolTip ID="rdTitleToolTip" runat="server" TargetControlID="DownloadLink"
                                Width="200" RelativeTo="Element" Position="MiddleLeft">
                                <strong>
                                    <%# DataBinder.Eval(Container, "DataItem.Title") %></strong><br />
                                <%# DataBinder.Eval(Container, "DataItem.Summary")%>
                            </telerik:RadToolTip>
                        </ItemTemplate>
                        <ItemStyle VerticalAlign="Top" HorizontalAlign="Left" />
                    </telerik:GridTemplateColumn>
 
                    <telerik:GridBoundColumn DataField="FileSize" HeaderText="Size" UniqueName="column4"
                        AllowFiltering="False" AllowSorting="False">
                        <HeaderStyle HorizontalAlign="Center" />
                        <ItemStyle VerticalAlign="Top" HorizontalAlign="Center" />
                    </telerik:GridBoundColumn>
 
                    <telerik:GridDateTimeColumn DataField="LastUpdated" DataFormatString="{0:dd/MM/yyyy}"
                        HeaderText="Last Updated" UniqueName="column5" AllowFiltering="False">
                        <HeaderStyle HorizontalAlign="Center" />
                        <ItemStyle VerticalAlign="Top" HorizontalAlign="Center" />
                    </telerik:GridDateTimeColumn>
                </Columns>
            </MasterTableView>
            <PagerStyle AlwaysVisible="True" Mode="NumericPages" />
            <HeaderContextMenu EnableAutoScroll="True"></HeaderContextMenu>
        </telerik:RadGrid>
    </telerik:RadPane>
</telerik:RadSplitter>



string imageURL = "images/icons/mailfolder.gif";

private void GetTree()
{
    PDUser U = PDUser.GetCurrentUser();
    List<Folder> FolderList = Folder.GetFolders(U.SchemeID, 0, 0);
 
    foreach (Folder F in FolderList)
    {
        //Create parent
        RadTreeNode NewNode = new RadTreeNode();
        NewNode.ImageUrl = imageURL;
        NewNode.Text = F.FolderName + "<span style='font-style:italic; font-size:10px;'> (" + F.DocumentCount.ToString() + " files)</span>";
        NewNode.ToolTip = F.FolderName;
        NewNode.Value = F.FolderID.ToString();
 
        //Create children
        GetChild(U.SchemeID, U.UserID, F.FolderID, ref NewNode);
 
        rdTreeView.Nodes.Add(NewNode);
    }
}
 
private void GetChild(int SchemeID, int UserID, int FolderID, ref RadTreeNode NewNode)
{
    List<Folder> FolderList = Folder.GetFolders(SchemeID, 0, FolderID);
    foreach (Folder F in FolderList)
    {
        RadTreeNode ChildNode = new RadTreeNode(F.FolderName);
        GetChild(SchemeID, UserID, F.FolderID, ref ChildNode);
        ChildNode.ImageUrl = imageURL;
        ChildNode.Text = F.FolderName + "<span style='font-style:italic; font-size:10px;'> (" + F.DocumentCount.ToString() + " files)</span>";
        ChildNode.ToolTip = F.FolderName;
        ChildNode.Value = F.FolderID.ToString();
        NewNode.Nodes.Add(ChildNode);
    }
}
 
//Populate GridView with available documents
protected void rdTreeView_NodeClick(object sender, RadTreeNodeEventArgs e)
{
    PDUser U = PDUser.GetCurrentUser();
 
    string folderStr = e.Node.Value;
    int folderID = Convert.ToInt32(folderStr);
    List<Document> DocumentList = Document.GetDocuments(U.UserID, folderID);
 
    rdViewDocuments.DataSource = DocumentList;
    rdViewDocuments.DataBind();
    rdViewDocuments.Visible = true;
}

Kate
Telerik team
 answered on 22 Jun 2011
1 answer
68 views
Hi,

Is it possible to acheive RepeatColumns like property used in RadMenu with RadToolBar (RadToolBarDropDown)?

Thanks,
Sandeep
Kate
Telerik team
 answered on 22 Jun 2011
1 answer
206 views
hi,

i have update panel on my page and i want to use loading panel also. Loading panel should works when i click a combo box but update panel does not allow that. If i remove <asp:UpdatePanel runat="server"> loading panel works fine however i need <asp:UpdatePanel runat="server">  also.

thank you.. 
Maria Ilieva
Telerik team
 answered on 22 Jun 2011
1 answer
187 views
Hi guys,

What I need to do is bind the radscheduler data to a radgrid and search by date range.  Once the date range is selected it will only show those dates.  I have tried this with  sqldatasource, but I am not getting all the events.  I looked  at the following article:http://www.telerik.com/support/kb/aspnet-ajax/scheduler/how-to-display-all-radscheduler-appointments-in-gridview.aspx, works fine.  I now get eveything even all the recurring events.  I have 2 rad datepickers on the page.  One is RadStart the other is Radend.  When i do a date range search (SELECT * FROM [Visit] WHERE (([Start] >= @RadStart) AND ([End] <= @RadEnd))), I still get all the recurring events in my RadGrid. It is not showing me events only for that selected date range.
Any ideas?

Thank you,
Gus
Plamen
Telerik team
 answered on 22 Jun 2011
3 answers
109 views
Hi there,

We have an issue on a site that I was also able to recreate on a Telerik demo site, http://demos.telerik.com/aspnet-ajax/editor/examples/default/defaultcs.aspx.

In IE: If you paste in the folowing code:

<ul>
    <li><a href="AAA http://www.telerik.com/purchase">AAA</a></li>
    <li><a href="DDD https://www.telerik.com/login.aspx">DDD</a></li>
    <li><a href="FFF http://www.telerik.com/community">FFF</a></li>
    <li><a href="SSS http://www.telerik.com/support">SSS</a></li>
</ul>

into the HTML view, switch to design view, add a new list item (add a space somewhere in the middle of the new text if possible), select the list item (all text in item), it will select the text as well as one more character to the right. Make this text a link either by the link manager or the custom links drop-down. If you go to the HTML view, you see the code gets mangled because it selected that one character to the right, which I'm sure id the closing LI tag. If you do not select the last character it works fine, but it is very unintuitive and we could never tell our clients to check for the selection of that last character. Is this something you are working on, is fixed in a version soon to be released, or fixable with a config/tool XML file change? Any help would be so greatly appreciated.

Thanks so much,

Marco Andrade
Matz
Top achievements
Rank 1
 answered on 22 Jun 2011
1 answer
83 views
Hello! I'm having this problem) I use a grid and a hierarchical structure to display more information about the current record! And when I'm clicking on the icon > to open the additional information that this icon  a little bit lost (as in the picture!
Shinu
Top achievements
Rank 2
 answered on 22 Jun 2011
1 answer
91 views
Hi,
I have a problem with execution of few RadListBox Event: OnDeleted. Also I have discovered, that neither of following OnDeleting, OnReordering, OnReordered is being executed. While debugging it seems that they are not really invoked. Have you ever meet such problems.
Thanks for quick reply.

Control configuration:
<telerik:RadListBox ID="rlbDefinedShippings" runat="server" AllowReorder="true" AllowDelete="true" AutoPostBack="true" SelectionMode="Single" OnDeleted="rlbDefinedShippings_Deleted" />

Software configuration:
VS2010
RadControls version: 2010.3.1317.35
Princy
Top achievements
Rank 2
 answered on 22 Jun 2011
4 answers
256 views
I need to edit the records on my grid, doing exactelly what's explainned on the demo "Grid / Client edit with batch server update" (http://demos.telerik.com/aspnet-ajax/grid/examples/dataediting/clienteditbatchupdates/defaultcs.aspx)

The only problem is that i need to do it using server-side events, the datasource is created from a collection.

Is there any easier way to resolve this problem?

Thanks

Tiago Gerevini
Maria Ilieva
Telerik team
 answered on 22 Jun 2011
3 answers
102 views
Hy

I´ve create an application page using some RadControls. But the RadDateTimePicker is not working within the ApplicationPage. The Date and Time Dialogs do not pop up. I´ve used them in WebParts and they worked fine there, it seems to have something to do with the ApplicationPage.

Furthermore, if I use the Applicationpage within a ModalDialog (which I prefer to use) it is completely unusable. If I click on the Button for either Date or Time, a kind of Postback leaves the whole Modaldialog and reloads the page (only the page itself, even without the sharepointmasterpage).

Marin
Telerik team
 answered on 22 Jun 2011
8 answers
481 views

Two issues with RadChart legend position alignment (using RadControls for ASP.NET AJAX 2008.3.1314):

  1. Documentation suggests that "CenterRight" and "CenterLeft" are valid values for Legend.Appearance.Position.AlignedPostion; they are not. I'm assuming the correct values for the same positioning as shown in the image are "Right" and "Left".
  2. Setting AlignedPostion=Right results in the same positioning as AlignedPosition=TopRight. AlignedPosition=Right does not actually position the legend at the center-right as expected (instead it is actually positioned at the top-right); however, AlignedPosition=Left does position the legend at the center-left as expected.

    I'm setting Position-AlignedPosition declaratively in the markup:
    <Legend> 
        <Appearance Dimensions-Margins="15%, 2%, 1px, 1px" 
            Dimensions-Paddings="2px, 8px, 6px, 3px" Position-AlignedPosition="Right">  
            <ItemTextAppearance TextProperties-Color="Black">  
            </ItemTextAppearance> 
            <ItemMarkerAppearance Figure="Square">  
            </ItemMarkerAppearance> 
        </Appearance> 
    </Legend> 
     

 Here's the entire RadChart:

<telerik:RadChart ID="RadChart1" runat="server" SeriesOrientation="Vertical" Skin="Office2007" 
    DataSourceID="SqlDsRepairCosts" Width="800px">  
    <Series> 
        <telerik:ChartSeries DataYColumn="LABOR_OWL" DefaultLabelValue="#Y{c0}" Name="OWL Labor">  
        </telerik:ChartSeries> 
        <telerik:ChartSeries DataYColumn="LABOR_SFW" DefaultLabelValue="#Y{c0}" Name="SFW Labor">  
        </telerik:ChartSeries> 
        <telerik:ChartSeries DataYColumn="MATERIAL_COSTS" DefaultLabelValue="#Y{c0}" Name="Material Costs">  
        </telerik:ChartSeries> 
        <telerik:ChartSeries DataYColumn="TOTAL_ALLOCATED_SUPPORT_COSTS" DefaultLabelValue="#Y{c0}" 
            Name="Allocated Support Costs">  
        </telerik:ChartSeries> 
    </Series> 
    <PlotArea> 
        <XAxis Visible="False">  
            <Appearance Color="134, 134, 134" MajorTick-Color="134, 134, 134">  
                <MajorGridLines Color="134, 134, 134" Width="0" /> 
                <TextAppearance TextProperties-Color="Black">  
                </TextAppearance> 
            </Appearance> 
            <AxisLabel> 
                <Appearance RotationAngle="270">  
                </Appearance> 
                <TextBlock> 
                    <Appearance TextProperties-Color="Black">  
                    </Appearance> 
                </TextBlock> 
            </AxisLabel> 
        </XAxis> 
        <YAxis> 
            <Appearance Color="134, 134, 134" MajorTick-Color="134, 134, 134" MinorTick-Color="134, 134, 134" 
                CustomFormat="$#,##0">  
                <MajorGridLines Color="134, 134, 134" /> 
                <MinorGridLines Color="134, 134, 134" /> 
                <TextAppearance TextProperties-Color="Black">  
                </TextAppearance> 
            </Appearance> 
            <AxisLabel> 
                <Appearance RotationAngle="0">  
                </Appearance> 
                <TextBlock> 
                    <Appearance TextProperties-Color="Black">  
                    </Appearance> 
                </TextBlock> 
            </AxisLabel> 
        </YAxis> 
        <YAxis2> 
            <AxisLabel> 
                <Appearance RotationAngle="0">  
                </Appearance> 
            </AxisLabel> 
        </YAxis2> 
        <Appearance> 
            <FillStyle FillType="Solid" MainColor="">  
            </FillStyle> 
        </Appearance> 
    </PlotArea> 
    <Appearance> 
        <Border Color="134, 134, 134" /> 
    </Appearance> 
    <ChartTitle Appearance-Position-AlignedPosition="Top">  
        <Appearance> 
            <FillStyle MainColor="">  
            </FillStyle> 
        </Appearance> 
        <TextBlock Text="Repair Costs Breakdown">  
            <Appearance TextProperties-Color="Black" TextProperties-Font="Arial, 18px">  
            </Appearance> 
        </TextBlock> 
    </ChartTitle> 
    <Legend> 
        <Appearance Dimensions-Margins="15%, 2%, 1px, 1px" 
            Dimensions-Paddings="2px, 8px, 6px, 3px" Position-AlignedPosition="Right">  
            <ItemTextAppearance TextProperties-Color="Black">  
            </ItemTextAppearance> 
            <ItemMarkerAppearance Figure="Square">  
            </ItemMarkerAppearance> 
        </Appearance> 
    </Legend> 
</telerik:RadChart>

Am I doing something wrong?
Jimmy
Top achievements
Rank 1
 answered on 22 Jun 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Top achievements
Rank 1
Iron
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ivory
Top achievements
Rank 1
Iron
Nurik
Top achievements
Rank 2
Iron
Iron
YF
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Top achievements
Rank 1
Iron
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ivory
Top achievements
Rank 1
Iron
Nurik
Top achievements
Rank 2
Iron
Iron
YF
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?