|
Rank: Advanced Member Groups: Member
Joined: 9/6/2007 Posts: 133
|
I have an eo:AJAXUploader within an eo:CallbackPanel. It shows the "LoadingHTML" content just fine, but then when it's done the uploader does not reappear. This must be simple - but what am I doing wrong?
<eo:CallbackPanel ID="CallbackPanel2" runat="server" AutoDisableContents="true" LoadingHTML="<table cellpadding='10'><tr><td><img src='/_images/loading.gif'></td><td>Please wait as your PDF is uploaded to the Scribd server...</td></tr></table>" Triggers="{ControlID:AJAXUploader1;Parameter:}" UpdateMode="Self"> <eo:AJAXUploader AutoUpload="true" runat="server" ID="AJAXUploader1" Width="520px" MaxDataSize="30000" AutoPostBack="true" OnFileUploaded="AJAXUploader1_FileUploaded" TempFileLocation="~/temp"> <LayoutTemplate> <table cellspacing="0" cellpadding="2" width="520" border="0"> <tr id="postedfilesarea" runat="server" visible="false"> <td colspan="3"> <asp:PlaceHolder ID="PostedFilesPlaceHolder" runat="server">Posted Files Place Holder </asp:PlaceHolder> <asp:Button ID="DeleteButton" runat="server" Text="Delete Selected Files"></asp:Button> <p> </p> </td> </tr> <tr> <td width="99%"> <asp:PlaceHolder ID="InputPlaceHolder" runat="server">Input Box Place Holder</asp:PlaceHolder> </td> <td> <asp:Button ID="UploadButton" runat="server" Text="Upload"></asp:Button> </td> <td> <eo:ProgressBar ID="ProgressBar" runat="server" ControlSkinID="None" Height="18px" Width="150px" BorderColor="#336699" BorderStyle="Solid" BorderWidth="1px" IndicatorColor="151, 198, 232"> </eo:ProgressBar> </td> </tr> </table> </LayoutTemplate> </eo:AJAXUploader> </eo:CallbackPanel>
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,194
|
Hi,
We tested your code and it worked fine here. You may want to try it in a separate page without any server side code and see if that works.
Thanks!
|
|
Rank: Advanced Member Groups: Member
Joined: 9/6/2007 Posts: 133
|
OK, I got it working as a standalone test. It was not working when the sample code I posted was part of a larger page that was within another callback panel, at least not until I changed the UpdateMode for that parent callback panel to "Conditional".
HOWEVER - I have a new issue. I am now trying a simpler setup with just a single callback panel for the entire page except a navigation menu. No matter what I try, the contents within the callback panel are "squished together" and a flash object that is part of the contents is not being displayed at all. I tried changing all sorts of settings like the UpdateMode of the callback panel, the height, etc. Nothing changes it. If I use an AJAX toolkit Update Panel in place of the EssentialObjects callback panel, it works fine - but I would much prefer to use the EssentialObjects one. What the heck is going on??? Why is everything squished together? Here is a simplified version of my code:
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="test.aspx.cs" Inherits="_admin_test" %>
<%@ Register Assembly="EO.Web" Namespace="EO.Web" TagPrefix="eo" %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<script runat="server"> public string DocID = ""; public string AccessKey = ""; public string DocFileName = ""; </script>
<html xmlns="http://www.w3.org/1999/xhtml"> <head runat="server"> <title></title> </head> <body> <form id="form1" runat="server"> <div> <div style="width: 100%; border-top: #e0e0e0 1px solid; border-bottom: #e0e0e0 1px solid; background-image: url('/_images/menubg.gif');"> menu here... </div> <eo:CallbackPanel ID="CallbackPanel1" runat="server" Width="100%" LoadingHTML="<table cellpadding='10'><tr><td><img src='/_images/loading.gif'></td><td>Loading...</td></tr></table>" AutoDisableContents="False" UpdateMode="Group"> <eo:AJAXUploader AutoUpload="true" runat="server" ID="AJAXUploader1" MaxDataSize="30000" AutoPostBack="true" TempFileLocation="~/temp"> <LayoutTemplate> <table cellspacing="0" cellpadding="2" width="520" border="0"> <tr id="postedfilesarea" runat="server" visible="false"> <td colspan="3"> <asp:PlaceHolder ID="PostedFilesPlaceHolder" runat="server">Posted Files Place Holder </asp:PlaceHolder> <asp:Button ID="DeleteButton" runat="server" Text="Delete Selected Files"></asp:Button> <p> </p> </td> </tr> <tr> <td width="99%"> <asp:PlaceHolder ID="InputPlaceHolder" runat="server">Input Box Place Holder</asp:PlaceHolder> </td> <td> <asp:Button ID="UploadButton" runat="server" Text="Upload"></asp:Button> </td> <td> <eo:ProgressBar ID="ProgressBar" runat="server" ControlSkinID="None" Height="18px" Width="150px" BorderColor="#336699" BorderStyle="Solid" BorderWidth="1px" IndicatorColor="151, 198, 232"> </eo:ProgressBar> </td> </tr> </table> </LayoutTemplate> </eo:AJAXUploader> <table width="100%" cellpadding="0" cellspacing="0"> <tr> <td style="padding-top: 2px; padding-bottom: 2px; padding-left: 40px; border-top: #C0C0C0 0px solid;"> <asp:DropDownList ID="ddlMenu" runat="server" AutoPostBack="true"> </asp:DropDownList> </td> <td align="left" style="padding-top: 2px; padding-bottom: 2px; border-top: #C0C0C0 0px solid; padding-right: 4px; padding-right: 4px;"> <asp:HyperLink ID="HyperLink1" runat="server" Target="_blank" Text="Open as PDF (large file size)"></asp:HyperLink> </td> <td align="left" style="padding-top: 2px; padding-bottom: 2px; border-top: #C0C0C0 0px solid; padding-right: 4px; padding-right: 4px;"> <asp:LinkButton ID="lbDeleteNewsletter" runat="server"></asp:LinkButton> </td> </tr> </table> <object codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0" id="-671065188" name="-671065188" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" align="middle" height="600" width="798"> <param name="movie" value="http://documents.scribd.com/ScribdViewer.swf?document_id=<%= DocID %>&access_key=<%= AccessKey %>&page=1&version=1&mode=tile"> <param name="quality" value="high"> <param name="play" value="true"> <param name="loop" value="true"> <param name="scale" value="showall"> <param name="wmode" value="opaque"> <param name="devicefont" value="false"> <param name="bgcolor" value="#ffffff"> <param name="menu" value="true"> <param name="allowFullScreen" value="true"> <param name="allowScriptAccess" value="always"> <param name="salign" value=""> <embed src="http://documents.scribd.com/ScribdViewer.swf?document_id=<%= DocID %>&access_key=<%= AccessKey %>&page=1&version=1&mode=tile" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" play="true" loop="true" scale="showall" wmode="opaque" devicefont="false" bgcolor="#ffffff" name="-671065188_object" menu="true" allowfullscreen="true" allowscriptaccess="always" salign="" type="application/x-shockwave-flash" align="middle" height="600" width="798"></embed> </object> </eo:CallbackPanel> </div> </form> </body> </html>
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,194
|
Hi, We verified the code and it works fine as soon as we remove all the argument for this line: http://documents.scribd.com/ScribdViewer.swf?document_id=<%= DocID %>&access_key=<%= AccessKey %>&page=1&version=1&mode=tile And change it to: http://documents.scribd.com/ScribdViewer.swfSo it appears that something is wrong with the flash when the arguments are not correctly provided. Thanks
|
|
Rank: Advanced Member Groups: Member
Joined: 9/6/2007 Posts: 133
|
OK - that's a step closer, but there is still something going on with the callback panel that is preventing this from working. I changed the flash to the sample pasted below. Even if I leave the value of the variable strEmbedLine as blank ("") it does not work. If I assign a value to strEmbedLine (such as strEmbedLine = "?document_id=" + DocID + "&access_key=" + AccessKey + "&page=1&version=1&mode=tile";) it still does not work. strEmbedLine is a public variable initially defined as (public string strEmbedLine = "";) whose value I set at Page_Load (but I also tried leaving the value blank).
Without the callback panel, it all work fine. With a .Net updatepanel, it all works fine. Something is unique to the callback panel that is preventing it from working.
<object codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0" id="-671065188" name="-671065188" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" align="middle" height="600" width="798"> <param name="movie" value="http://documents.scribd.com/ScribdViewer.swf<%=strEmbedLine %>"> <param name="quality" value="high"> <param name="play" value="true"> <param name="loop" value="true"> <param name="scale" value="showall"> <param name="wmode" value="opaque"> <param name="devicefont" value="false"> <param name="bgcolor" value="#ffffff"> <param name="menu" value="true"> <param name="allowFullScreen" value="true"> <param name="allowScriptAccess" value="always"> <param name="salign" value=""> <embed src="http://documents.scribd.com/ScribdViewer.swf<%=strEmbedLine %>" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" play="true" loop="true" scale="showall" wmode="opaque" devicefont="false" bgcolor="#ffffff" name="-671065188_object" menu="true" allowfullscreen="true" allowscriptaccess="always" salign="" type="application/x-shockwave-flash" align="middle" height="600" width="798"></embed> </object>
|
|