Hi Ted,
According to what you have said, the attached below example should work, but it does not, and I cannot figure out what is wrong with this picture. Could you, may be, take a look?
Thank you,
Tomasz
<%@ Page Language="C#" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head>
<title>Animation Demo</title>
<meta name="description" content="MS Ajax Animation Demo" />
<meta name="author" content="Tomasz Jastrzebski" />
</head>
<body style="text-align:center;">
<form id="form1" runat="server">
<script src="./scripts/MicrosoftAjax.debug.js" type="text/javascript"></script>
<script src="./scripts/MicrosoftAjaxWebForms.debug.js" type="text/javascript"></script>
<script src="./scripts/MicrosoftAjaxTimer.debug.js" type="text/javascript"></script>
<script src="./scripts/Animations.js" type="text/javascript"></script>
<script src="./scripts/BaseScripts.js" type="text/javascript"></script>
<div>
<input type="button" value="Click Me" onclick="show();return false;" />
</div>
<div id="popup" style="display:none; cursor:hand;" title="click to hide" onclick="hide();">
<table style="width:100%; height:100%;">
<tr><td style="text-align:center; vertical-align:middle;">
TEST
</td></tr>
</table>
</div>
<script type="text/javascript">
<!--
Sys.Application.initialize();
function show() {
var animation = new AjaxControlToolkit.Animation.SequenceAnimation();
// StyleAction(target, duration, fps, attribute, value)
var action = new AjaxControlToolkit.Animation.StyleAction("popup", null, null, "display", "block");
animation.add(action);
// ResizeAnimation(target, duration, fps, width, height, unit)
action = new AjaxControlToolkit.Animation.ResizeAnimation("popup", .3, 25, 300, 300, "px");
animation.add(action);
animation.play("popup", null, null);
}
function hide() {
var animation = new AjaxControlToolkit.Animation.SequenceAnimation();
var action = new AjaxControlToolkit.Animation.ResizeAnimation("popup", .3, 25, 0, 0, "px");
animation.add(action);
action = new AjaxControlToolkit.Animation.StyleAction("popup", null, null, "display", "none");
animation.add(action);
animation.play("popup", null, null);
}
//-->
</script>
</form>
</body>
</html>