- Upload Suite Overview
- What's New?
- Choosing Upload Technology
- Evaluating Upload Suite
- Upload Suite Editions
- System Requirements
- Installation and Deployment Notes
- ActiveX/Java Uploader
- HTML5/Flash Uploader
- Before You Started with HTML5/Flash Uploader
- HTML5/Flash Uploader Architecture
- HTML5/Flash Uploader User Interface
- Getting Started
- Using HTML5/Flash Uploader
- Troubleshooting
- Reference
- HTML5/Flash Uploader ASP.NET Reference
- HTML5/Flash Uploader PHP Reference
- HTML5/Flash Uploader JavaScript Reference
- HTML5/Flash Uploader Client-Side Events Reference
- ImageUploaderFlash Client-Side Events
- AfterPackageUpload Event HTML5/Flash Uploader
- AfterUpload Event HTML5/Flash Uploader
- BeforePackageUpload Event HTML5/Flash Uploader
- BeforeSendRequest Event HTML5/Flash Uploader
- BeforeUpload Event HTML5/Flash Uploader
- Error Event HTML5/Flash Uploader
- ImageEditorClose Event HTML5/Flash Uploader
- InitComplete Event HTML5/Flash Uploader
- PreRender Event HTML5/Flash Uploader
- Progress Event HTML5/Flash Uploader
- RestrictionFailed Event HTML5/Flash Uploader
- SelectionChange Event HTML5/Flash Uploader
- UploadFileCountChange Event HTML5/Flash Uploader
- ImageUploaderFlash Client-Side Events
- POST Field Reference
- Licensing Information
- Legal Notices
ImageUploaderFlash.RestrictionFailed Event HTML5/Flash Uploader
Supported technologies:

This event fires when some restriction is broken.
Syntax
ASP.NET
<script type="text/javascript">
function ImageUploaderFlash1_RestrictionFailed(errorCode, fileName, message){
//...your code...
}
</script>
<aur:ImageUploaderFlash ID="ImageUploaderFlash1" runat="server">
<ClientEvents>
<aur:ClientEvent EventName="RestrictionFailed" HandlerName="ImageUploaderFlash1_RestrictionFailed" />
</ClientEvents>
</aur:ImageUploaderFlash>
PHP
<script type="text/javascript">
function ImageUploaderFlash1_RestrictionFailed(errorCode, fileName, message){
//...your code...
}
</script>
<?php
$ImageUploaderFlash = new ImageUploaderFlash("ImageUploaderFlash1");
//...other params...
$ImageUploaderFlash->getClientEvents()->setRestrictionFailed("ImageUploaderFlash1_RestrictionFailed");
//...other params...
$ImageUploaderFlash->render();
?>
JavaScript
function ImageUploaderFlash1_RestrictionFailed(errorCode, fileName, message){
//...your code...
}
$au.imageUploaderFlash({
events: {
//...other params...
restrictionFailed: [ImageUploaderFlash1_RestrictionFailed],
//...other params...
}
})
Parameters
- errorCode
-
Type: Number
One of the following values:
- 0 - size of the selected file exceeds the MaxFileSize value;
- 1 - size of the selected files is less than the MinFileSize value;
- 3 - dimensions of the selected image are too large (i.e. image width or height exceeds the MaxImageHeight or MaxImageWidth value);
- 4 - dimensions of the selected image are too small (i.e. image width or height is less than the MinImageHeight or MinImageWidth value);
- 5 - the selected file has not allowed name (i.e. filename does not match FileMask;
- 6 - number of selected files exceeds the MaxFileCount value;
- 7 - total size of selected files exceeds the MaxTotalFileSize value;
- 11 - a warning displayed when a user adds a folder with too many files with drag-and-drop (some of files are ignored due to a Chrome bug).
- fileName
-
Type: String
The name of the file which breaks the restriction.
- message
-
Type: String
The message stating that the restriction is broken. The same message is displayed in the information bar.