Hi Andy,
Please try the way below. handlebrowse will fire when the user click on the uploader button, you can achieve your own logic in it.
- <%@ Page Language="C#" %>
-
- <!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>example</title>
- </head>
- <body>
- <form id="form1" runat="server">
- <table>
- <tr>
- <td>
- store path:
- </td>
- <td>
- <asp:TextBox ID="tbPath" runat="server"></asp:TextBox>
- </td>
- </tr>
- <tr>
- <td>
- </td>
- <td>
- <CuteWebUI:Uploader ID="Uploader1" runat="server">
- </CuteWebUI:Uploader>
- </td>
- </tr>
- </table>
- </form>
- </body>
- </html>
-
- <script type="text/javascript">
- var uploader1=document.getElementById('<%=Uploader1.ClientID%>')
- var tbPath=document.getElementById('<%=tbPath.ClientID%>')
- uploader1.handlebrowse=function()
- {
- if(tbPath.value==null||tbPath.value=="")
- {
- alert("please select the store path");
- return false;
- }
- }
- </script>
Regards,
Ken