SEARCH
0-9 A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
Prev | Current Page 270 | Next

Robin Pars, Laurence Moroney, and John Grieb

"Foundations of ASP.NET AJAX"

gif"
AlternateText="ASP.NET AJAX" style="width:100%; height:100%;" />

We could enable this panel to be resizable by using the ResizableControl extender
and assigning its TargetControlID property to the ID of this Panel:
TargetControlID="PanelImage"
ResizableCssClass="resizingImage"
HandleCssClass="handleImage"
CHAPTER 8 ?–  USING THE ASP.NET AJAX CONTROL TOOLKIT (PART 2) 195
MinimumWidth="50"
MinimumHeight="26"
MaximumWidth="250"
MaximumHeight="170"
HandleOffsetX="3"
HandleOffsetY="3"
OnClientResize="OnClientResizeImage" />
The OnClientResize property defines a client-side function to execute when the
image is resized, which in this case has the following script:
function OnClientResizeImage(sender, eventArgs) {
$get("lastResize").innerHTML = "Last image resize at " + (new Date()).toString();
}
You can use HandleCssClass, HandleOffsetX, and HandleOffsetY to better control the
appearance of the lower-right drag handle for the resize. Furthermore, using the
OnClientResize property, you can write a client-side JavaScript function to modify the behavior
of the extender as the underlying control is being resized.


Pages:
258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282