atlas:DragOverlayExtender

I was looking into the atlas:DragOverlayExtender
control today and puzzling over why whenever I drag a panel around the
browser the the panel is always redrawn at the starting position when I
let go of the mouse.  Try adding the following code as an ATLAS ASP.NET
page, running the project and dragging the panel around…

<%@ Page Language=”C#” AutoEventWireup=”true” CodeFile=”Default.aspx.cs” Inherits=”_Default” %>
<!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.1//EN” “http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd”>
<html xmlns=”http://www.w3.org/1999/xhtml”>
<head runat=”server”>
<title>Untitled Page</title>
</head>
<body>
<atlas:ScriptManager ID=”ScriptManager1″ runat=”server” />
<form id=”form1″ runat=”server”>
<!– Get a proxy for Profile –>
<atlas:ProfileScriptService ID=”profile” runat=”server” AutoSave=”true”>
</atlas:ProfileScriptService>
<!– Our drop zone (think of it as the BODY area) –>
<div class=”dropZone”>
<!– A button to do postback, just for testing the Profile feature –>
<asp:Button ID=”pbButton” runat=”server” Text=”Postback” />
<!– The floating label –>
<asp:Label ID=”floatingLabel” runat=”server” CssClass=”label”>Please DragMe around</asp:Label>
</div>
<!– The extender for our label –>
<atlas:DragOverlayExtender ID=”doe1″ runat=”server”>
<atlas:DragOverlayProperties TargetControlID=”floatingLabel” ProfileProperty=”FloatingLabelLocation”
Enabled=”true” />
</atlas:DragOverlayExtender>
</form>
</body>
</html>

It seems that ATLAS will only enable you to drop the panel within a
browser area depicted by the amount of HTML rendered. In the above
case, the page has very little content between the body tags (most of
the page is whitespace), so the panel cannot be dropped far from the
start location. Adding a style to the body tag and setting the height
to 100% seems to fix the problem…

<body style=”height:100%;”>

3 thoughts on “atlas:DragOverlayExtender

  1. http://

    I had this problem, was driving me nutts. Thanks for your post, the solution makes sense and works.

    Reguards

  2. http://

    I had a similar problem where despite the fact there was valid html further down the page, it would not drag beyond a certain point.

    Turned out that omitting a DTD directive at the top of the page causes an issue, specifically:

    <!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.1//EN” “http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd”>

    Thanks for help,

Comments are closed.