Loading ...
Sorry, an error occurred while loading the content.
 

this._swf.setAllowMultipleFiles is not a function

Expand Messages
  • hatfinch
    Hi, When I try to call setAllowMultipleFiles(true) on a new YAHOO.widget.Uploader, it fails for the reason stated in this message s subject. Am I doing
    Message 1 of 2 , Sep 7 1:01 PM
      Hi,

      When I try to call setAllowMultipleFiles(true) on a new YAHOO.widget.Uploader, it fails for the reason stated in this message's subject. Am I doing something wrong?

      YAHOO.util.Event.onDOMReady(function() {
      YAHOO.widget.Uploader.SWFURL = '/.../uploader.swf';
      var uploader = new YAHOO.widget.Uploader('uploaderOverlay');
      uploader.setAllowMultipleFiles(true);
      uploader.addListener('fileSelect', onFileSelect);
      });

      Thanks,
      H
    • viruschidai
      My guess is the error happened because the flash component had not loaded yet. Try to call uploader.setAllowMultipleFiles(true) in the contentReady handler.
      Message 2 of 2 , Sep 7 6:42 PM
        My guess is the error happened because the flash component had not loaded yet.
        Try to call uploader.setAllowMultipleFiles(true) in the contentReady handler. See if it still happens.

        Code Example:
        uploader.addListener('contentReady', handleContentReady);
        function handleContentReady () {
        // Allows multiple file selection in "Browse" dialog.
        uploader.setAllowMultipleFiles(true);
        }


        regards,
        Bill

        --- In ydn-javascript@yahoogroups.com, "hatfinch" <hamish@...> wrote:
        >
        > Hi,
        >
        > When I try to call setAllowMultipleFiles(true) on a new YAHOO.widget.Uploader, it fails for the reason stated in this message's subject. Am I doing something wrong?
        >
        > YAHOO.util.Event.onDOMReady(function() {
        > YAHOO.widget.Uploader.SWFURL = '/.../uploader.swf';
        > var uploader = new YAHOO.widget.Uploader('uploaderOverlay');
        > uploader.setAllowMultipleFiles(true);
        > uploader.addListener('fileSelect', onFileSelect);
        > });
        >
        > Thanks,
        > H
        >
      Your message has been successfully submitted and would be delivered to recipients shortly.