Hey Ankit,

  AFAIK, you wont get to know the size of the file unless you transfer it to
the server. But from the client side you can restrict the file extension by
extracting the file name as follows :

    final FileUpload upload = new FileUpload();
        upload.setName("uploadFormElement");
        absolutePanel.add(upload,8,37);
        String fileNameVal = upload.getFilename();

  You can put appropriate check to ensure that certain kind of files alone
can be uploaded.

  HTH,

Regards,
Abhi


On Wed, May 5, 2010 at 2:04 PM, GWT Groups <[email protected]> wrote:

> Hello Friends
>
> I am back to ask a question, Friends I want some views from your side
> about that
> "How to prevent the big and specific file to be uploaded?"
>
> I want that prevent the pdf file to be uploaded.
>
> I don't know how to do it?
>
>
> Please help me
>
> Your friends
> Ankit
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected]<google-web-toolkit%[email protected]>
> .
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.

Reply via email to