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

Get RadDock Tag property on client side

6 Answers 95 Views
Dock
This is a migrated thread and some comments may be shown as answers.
salk
Top achievements
Rank 1
salk asked on 01 Sep 2009, 06:46 PM
how to get TAG property of RadDock on client side?

thanx

6 Answers, 1 is accepted

Sort by
0
Vyrban
Top achievements
Rank 1
answered on 03 Sep 2009, 12:22 PM
Depends on many things. RadDock is rendering as DIV, but if you want to take its tagName property, try this one in JS:
var tag = $find("RadDock1").get_element().tagName;

Of course the RadDock ID must be "RadDock1" ;)
0
salk
Top achievements
Rank 1
answered on 03 Sep 2009, 02:41 PM
let me explain...

in code behind i have

RadDock.Tag = "RadDockZone1";

And then I want on client side get that property...

I want to be able when I drag RadDock on other zone and when i click X that RadDock dock to first starting dock zone and to do that I need to store some extra value.. the name of starting dock zone. I need to do that because I have 6 dock zones...
0
Vyrban
Top achievements
Rank 1
answered on 04 Sep 2009, 02:04 PM
ok, so why don't you use hidden fields to save needed information?

If they can't help you - try to explain more detailed your case, because i don't understand your scenario.
0
Vyrban
Top achievements
Rank 1
answered on 18 Sep 2009, 08:43 AM
If you have many docks or unknown quantity of them, you can use in JS :
        var tag = "<%= RadDock1.Tag %>"
for each of them. Hope this helps you.
0
J
Top achievements
Rank 1
answered on 09 Aug 2011, 02:41 PM
Developers want to use Tag property for this because Tag is advertised as being created for developers to store additional data.

I would like to make use of it as well and I'm trying to find a way to access the tag on clientside to save the ID of my dynamically created RadDockZone which contains my dynamically created dock control ;)

No luck just yet

0
Slav
Telerik team
answered on 11 Aug 2011, 01:14 PM
Hello,

Yet another option, in addition to the previously suggested ones, is to use RadDock's Attributes property to set new attribute, storing the additional data.
RadDock1.Attributes.Add("key", "Saved data");

You can then access the value of the new attribute on the client-side, as shown in the example below:
var radDock = $find("<%=RadDock1.ClientID %>"); // the RadDock control is referenced
var key = radDock.get_element().getAttribute("key"); // the attribute value is accessed

I have logged the requested feature in the Public Issue Tracking System, you can check it by following this link: Public URL. We will consider implementing it in a future release of the RadControls for ASP.NET AJAX if it gains enough interest.

Greetings,
Slav
the Telerik team

Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.

Tags
Dock
Asked by
salk
Top achievements
Rank 1
Answers by
Vyrban
Top achievements
Rank 1
salk
Top achievements
Rank 1
J
Top achievements
Rank 1
Slav
Telerik team
Share this question
or