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

Clickable items inside panel bar

3 Answers 55 Views
PanelBar
This is a migrated thread and some comments may be shown as answers.
Jaime
Top achievements
Rank 1
Jaime asked on 08 Mar 2013, 01:18 PM
I have a panel bar that is dynamically populated with items that represent answers to questions in a survey. The problem I am having is that the items (answers) are displayed inside an href tag which is not exactly what I want. How can I prevent the panel bar from adding an href tag to items inside?

Thanks,

Jaime

3 Answers, 1 is accepted

Sort by
0
Ivan Zhekov
Telerik team
answered on 13 Mar 2013, 09:20 AM
Hi, Jamie.

You can't really prevent the items from being rendered as links: you could use templates (templates render DIV elements), but that's as far as you can change items.

On a related note, if using PanelBar is required for its collapsing capabilities, why not use content template with RadioButtonList inside? (See attached example.)

Of course, if your scenario does not allow for the above solution, or PanelBar is required for other reasons and links (A elements) are note an option, templates are only solution.

Regards,
Ivan Zhekov
the Telerik team
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 their blog feed now.
0
Jaime
Top achievements
Rank 1
answered on 14 Mar 2013, 12:24 PM
In my solution the data being displayed in dynamically loaded so could you suggest how to accomplish this in the codebehind?

Thanks,

Jaime
0
Boyan Dimitrov
Telerik team
answered on 19 Mar 2013, 11:26 AM
Hello,

In order to achieve that functionality from the code behind, I would suggest adding templates at run-time. Here you may find a more information about it and some sample code illustrating that approach.


Kind regards,
Boyan Dimitrov
the Telerik team
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 their blog feed now.
Tags
PanelBar
Asked by
Jaime
Top achievements
Rank 1
Answers by
Ivan Zhekov
Telerik team
Jaime
Top achievements
Rank 1
Boyan Dimitrov
Telerik team
Share this question
or