Dear Telerik,
Currently I have 4 different RadDockZone each with a RadDock in it. On the bottom of my page I have a RadRotator with 10 RadDockZone each with a RadDock too. Inside each RadDock I have the RadChart to display the chart from my SQL database. Currently I'm using these code to drag and exchange RadDock between zones, and it's working great.
I would like that whenever I drag a RadDock into the rotator, the dock would display an Image instead of the RadChart's graph. Each of the raddock should has its own image.The initial RadDock in the Rotator on page load only display the image too. Is this something possible to do using Javascript, or I have to do with code behind and autopostback?
I've been trying to figure out without success. Please help me on this problem.
Thank you,
Loc Huynh
Currently I have 4 different RadDockZone each with a RadDock in it. On the bottom of my page I have a RadRotator with 10 RadDockZone each with a RadDock too. Inside each RadDock I have the RadChart to display the chart from my SQL database. Currently I'm using these code to drag and exchange RadDock between zones, and it's working great.
<script type="text/javascript">
// Javascript for swapping between DockZones
var initialZone;
var initialIndex;
function OnDragStart(dock, args)
{
initialIndex = dock.get_index();
initialZone = dock.get_dockZone();
}
function OnClientDockPositionChanged(dock, args)
{
var currentZone = dock.get_dockZone();
var dockToBeDocked = currentZone.get_docks()[dock.get_index() + 1];
if (dockToBeDocked != null && initialZone != null && currentZone != initialZone)
{
initialZone.dock(dockToBeDocked, initialIndex);
}
}
</script>
// Javascript for swapping between DockZones
var initialZone;
var initialIndex;
function OnDragStart(dock, args)
{
initialIndex = dock.get_index();
initialZone = dock.get_dockZone();
}
function OnClientDockPositionChanged(dock, args)
{
var currentZone = dock.get_dockZone();
var dockToBeDocked = currentZone.get_docks()[dock.get_index() + 1];
if (dockToBeDocked != null && initialZone != null && currentZone != initialZone)
{
initialZone.dock(dockToBeDocked, initialIndex);
}
}
</script>
I would like that whenever I drag a RadDock into the rotator, the dock would display an Image instead of the RadChart's graph. Each of the raddock should has its own image.The initial RadDock in the Rotator on page load only display the image too. Is this something possible to do using Javascript, or I have to do with code behind and autopostback?
I've been trying to figure out without success. Please help me on this problem.
Thank you,
Loc Huynh