This is a migrated thread and some comments may be shown as answers.

Databinding RadTileList

3 Answers 157 Views
TileList
This is a migrated thread and some comments may be shown as answers.
Walther Siksma
Top achievements
Rank 2
Walther Siksma asked on 20 Jun 2013, 10:37 AM
I would like to load an entire list of tiles from a database. 
Is there any way to add Tiles programmatically via codebehind ( Radtilelist1.Tiles.Add ( new (radtile ....... '
or build tiles dynamically via databinding?


I did find  Databind and EnableDynamicData  methods but I could not find any documentation on how to implement that.
Any hint appreciated :)

3 Answers, 1 is accepted

Sort by
0
Marin Bratanov
Telerik team
answered on 20 Jun 2013, 01:30 PM
Hi Walther,

I am afraid databinding is not available in the beta release of the control. We are planning to have that feature for the Q3 2013 release when we are also aiming to move the control out of the beta phase.

For the time being you can create tiles programmatically like any other sever controls and here is a basic example:
protected void Page_Init(object sender, System.EventArgs e)
{
    RadTileList tl = new RadTileList();
    TileGroup tg = new TileGroup();
    tl.Groups.Add(tg);
 
    for (index = 1; index <= 5; index++)
    {
        RadTextTile tile = new RadTextTile();
        //you can also use the other tile types, I am using one for brevity
        tile.Text = "tile number " + index;
        tile.Badge.Value = index;
        tg.Tiles.Add(tile);
    }
 
    Placeholder1.Controls.Add(tl);
}

<form id="form1" runat="server">
<asp:ScriptManager ID="Scriptmanager1" runat="server" />
<asp:Button ID="Button1" Text="postback" runat="server" />
<asp:PlaceHolder ID="Placeholder1" runat="server" />
</form>

You can examine the RadTile's server-side API for mode details on the available properties.


Regards,
Marin Bratanov
Telerik
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.
0
Mayur
Top achievements
Rank 1
answered on 09 Aug 2013, 07:59 PM
How would I do this same thing in "ASP.Net MVC" aspx engine (and/or razor engine)?
0
Marin Bratanov
Telerik team
answered on 13 Aug 2013, 08:49 AM
Hi Mayur,

I have already responded to your ticket on the same subject and here is my answer for other people that may have a similar question:


I am afraid a TileList for MVC is not in our immediate plans and the RadControls for ASP.NET AJAX cannot be used with this engine (Razor).
The RadTileList is not tested for MVC and I cannot guarantee its full compatibility. Moreover, with the databinding we are working on for Q3 2013 it will be coupled more tightly with the WebForm lifecycle and architecture (e.g. viewstate, events).
You can try using a webform to add the control or an iframe that will point to a regular aspx webform page.


Regards,
Marin Bratanov
Telerik
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.
Tags
TileList
Asked by
Walther Siksma
Top achievements
Rank 2
Answers by
Marin Bratanov
Telerik team
Mayur
Top achievements
Rank 1
Share this question
or