Hi mremigion,
The example below shows you how to remove the files after uploaded in method "UploadCompleted".
- <%@ Page Language="C#" %>
-
- <%@ Import Namespace="CuteWebUI" %>
- <%@ Register TagPrefix="CuteWebUI" Namespace="CuteWebUI" Assembly="CuteWebUI.AjaxUploader" %>
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-
- <script runat="server">
-
- protected void attachment1_UploadCompleted(object sender, UploaderEventArgs[] args)
- {
- for (int i = attachment1.Items.Count - 1; i >= 0; i--)
- {
- attachment1.Items[i].Remove();
- }
- }
-
- protected void attachment1_FileUploaded(object sender, UploaderEventArgs args)
- {
-
-
- }
- </script>
-
- <html xmlns="http://www.w3.org/1999/xhtml">
- <head id="Head1" runat="server">
- <title>Untitled Page</title>
- </head>
- <body>
- <form id="form1" runat="server">
- <CuteWebUI:UploadAttachments ID="attachment1" runat="server" OnUploadCompleted="attachment1_UploadCompleted" OnFileUploaded="attachment1_FileUploaded">
- </CuteWebUI:UploadAttachments>
- </form>
- </body>
- </html>
Regards,
Ken