Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
40
how to fix WebUpload problem
posted

I am trying to upload files in WebUpload 2012.1 version.

i added some references,<script type="text/javascript" src="~/ig_ui/js/infragistics.js"></script> , etc.      

But it is not working and i have Message that is "The Infragistics WebUpload requires its own script to be loaded."

I didin't find answer in this Forums. Can you please tell me how do i FIX ?

I appreciate if you have answer.

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="up1.aspx.cs" Inherits="up1" %>

<%@ Register assembly="Infragistics4.Web.jQuery.v12.1, Version=12.1.20121.2236, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb" namespace="Infragistics.Web.UI.EditorControls" tagprefix="ig" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
  <link type="text/css" href="~/ig_ui/css/themes/infragistics/infragistics.theme.css" rel="stylesheet" />
  <link type="text/css" href="~/ig_ui/css/structure/infragistics.css" rel="stylesheet" />

  <script type="text/javascript" src="http://code.jquery.com/jquery-1.4.4.js"></script>
    <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/jquery-ui.js"></script>
  <script type="text/javascript" src="~/ig_ui/js/infragistics.js"></script>   
    <script type="text/javascript" language="javascript">
     $(function () {
      $("#upload").igUpload({
       mode: "single",
       autostartupload: true,
       // to upload a file, you need a server-side handler
       progressUrl: "IGUploadStatusHandler.ashx",
       controlId: "serverID"
      });
     });
    </script>


    <script type="text/javascript" language="javascript">
     function onErrorHandler(e, args) {
      var message = "ErrorCode" + ": " + args.errorCode + "<br />" +
              "ErrorMessage" + ": " + args.errorMessage + "<br />" +
               "ErrorType " + ": " + args.errorType + "<br />" +
                "ServerMessage" + ": " + args.serverMessage;

      alert(message);

     }
   </script>
</head>
<body>
    <form id="form1" runat="server">
  <div id="upload">
       <ig:WebUpload ID="WebUpload1" runat="server"  Mode="Single" AutoStartUpload="true">
    <ClientEvents OnError="onErrorHandler" />
   </ig:WebUpload>
   
    </div>
    </form>
</body>
</html>

webupload.zip
Parents
  • 17590
    Verified Answer
    Offline posted

    Hello Lee MH,

    Thank you for posting in our community.

    What I noticed from the sample project provided is that you are trying to reference a script that is not actually present in the directory from the path used to reference it. This is the jQuery.tmpl.js file .

    Additionally, I noticed that the path used for referencing Infragistics.js script where all necessary scripts for the igUpload are located, is not correct. This means that script for the Uploader are not loaded ant this is the reason for the exception thrown in your browser. What I can suggest is using the following path for the Infragistics.js script:

    <script type="text/javascript" src="http://code.jquery.com/jquery-1.4.4.js"></script>

    <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/jquery-ui.js"></script>

    <%--<script type="text/javascript" src="~/ig_ui/js/jquery.tmpl.js"></script> --%>

    <script type="text/javascript" src="ig_ui/js/infragistics.js"></script>

    <%--<script type="text/javascript" src="~/ig_ui/js/infragistics.js"></script>--%>

    <link type="text/css" href="~/ig_ui/css/themes/infragistics/infragistics.theme.css" rel="stylesheet" />

    <link type="text/css" href="~/ig_ui/css/structure/infragistics.css" rel="stylesheet" />

    I hope this helps you resolve your issue.

    Please let me know if you need any further assistance with this matter.

Reply Children