How to get file list? can you post a code split to show how to do it?
----------------------------------------------------------------------
public static native void getFiles() /*-{
var input [email protected]::fileUpload;
for (var i = 0; i < input.files.length; i++) {
$wnd.alert(input.files[i].name);
}
return
}-*/;
--------------------------------------------------------------------------
Above code will report error:
--------------------------------------------------------------------------
Caused by: com.google.gwt.core.client.JavaScriptException: (TypeError):
Cannot read property 'files' of undefined
--------------------------------------------------------------------------
On Wed, 2011-06-15 at 09:13 -0700, Thomas Broyer wrote:
> JSNI and JavaScriptObject "overlay types" FTW!
>
> --
> You received this message because you are subscribed to the Google
> Groups "Google Web Toolkit" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/google-web-toolkit/-/lNk39MwjwWgJ.
> To post to this group, send email to
> [email protected].
> To unsubscribe from this group, send email to 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.