Welcome Guest! You need to login or register to make posts.

Notification

Icon
Error

Options
Go to last post Go to first unread
aks  
#1 Posted : Sunday, September 19, 2004 11:54:00 AM(UTC)
aks

Rank: Advanced Member

Groups: Member
Joined: 5/6/2004(UTC)
Posts: 36

Hello..

I'm make End user can't upload file less than 500KB.

so.. search help chm files.. can't find that property. only maxfilesize property is being?

if {YES} that can i do it for that?
Fedor  
#2 Posted : Sunday, September 19, 2004 11:31:00 PM(UTC)
Fedor

Rank: Advanced Member

Groups: Member, Administration, Moderator
Joined: 7/28/2003(UTC)
Posts: 1,660

Thanks: 5 times
Was thanked: 76 time(s) in 74 post(s)
You can do it using UploadItems collection. Just add custom upload button and add following code to its onclick event handler:

Code:
for (i=1;i<=ImageUploader.UploadItems.Count;i++){
    var uploadItem = ImageUploader.UploadItems.Item(i)
    if (uploadItem.FileSize<512000){
        alert(uploadItem.FileName + " is smaller then 500KB");
        return false;
    }
}

ImageUploader.Send():


Note, this code is untested.



========================================================
02/14/2008, Fedor
This topic is out of date.

Image Uploader supports MinFileSize property.
========================================================



Edited by user Tuesday, February 26, 2008 2:38:08 AM(UTC)  | Reason: Not specified

Best regards,
Fedor Skvortsov
aks  
#3 Posted : Monday, September 20, 2004 12:09:00 AM(UTC)
aks

Rank: Advanced Member

Groups: Member
Joined: 5/6/2004(UTC)
Posts: 36

Thank you Fedor..

I will test this code tomorrow.. and post that result.

See ya.. (H)
Users browsing this topic
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.