Welcome Guest Search | Active Topics | Sign In | Register

AJAX Uploader & Visual Studio 2008 Options
Dennis
Posted: Thursday, January 8, 2009 8:38:56 AM
Rank: Newbie
Groups: Member

Joined: 1/8/2009
Posts: 3
Hi,

I am building a web application in Visual Studio 2008 and attempting to use the AJAX Uploader.

I am using the Auto Postback as a sample. When I run the application in debug, the uploader dialog displays properly but I am unable to click on the browse button.

Could the fact that the web app is an AJAX application make a difference.

Code: HTML/ASPX
<asp:ScriptManager ID="ScriptManager1" runat="server">
   </asp:ScriptManager>

<div id="FileUpload"> 
    <eo:CallbackPanel runat="server" id="CallbackPanel1" Triggers="{ControlID:AJAXUploader1;Parameter:}">
    <eo:AJAXUploader id="AJAXUploader1" runat="server" Width="400px" TempFileLocation="~/App_Date/eo_upload" MaxDataSize="30000"
		        Rows="2" AutoPostBack="True"></eo:AJAXUploader>
	        <asp:Label id="lblResult" Runat="server"></asp:Label>
        </eo:CallbackPanel>
 </div>


Thanks,
Dennis
eo_support
Posted: Thursday, January 8, 2009 8:44:13 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,089
Hi,

AJAX should not matter and your code looks fine to us. It may have something to do with other contents in your page. I am not sure what you meant by "uploader dialog", can you clarify?

If the problem continues, please post the full page source that reproduces the problem. We will be happy to take a look once we have that.

Thanks!
Dennis
Posted: Thursday, January 8, 2009 8:50:44 AM
Rank: Newbie
Groups: Member

Joined: 1/8/2009
Posts: 3
Thanks for the quick response.

Without the code behind and dbml data access; here is the entire default.aspx page.

Code: HTML/ASPX
<%@ Page Language="C#" MasterPageFile="~/Site.master" AutoEventWireup="true"  CodeFile="Default.aspx.cs" Inherits="_Default" StylesheetTheme="MSN_Blue" %>

<%@ Register TagPrefix="eo" NameSpace="EO.Web" Assembly="EO.Web" %>

<asp:Content ID="Content1" ContentPlaceHolderID="MainContent" Runat="Server">
     <asp:ScriptManager ID="ScriptManager1" runat="server">
    </asp:ScriptManager>
    <div id="headerComment">
            <br />
             
            <asp:Label ID="Label8" runat="server" CssClass="standard-text-uppercase" 
                Text="McKesson Horizon Business Insight (HBI)  File Uploader" 
                Font-Bold="True"></asp:Label>
            <br />
            <br />
        </div>
        
        <div id="FileUpload"> 
    
        <eo:CallbackPanel runat="server" id="CallbackPanel1" Triggers="{ControlID:AJAXUploader1;Parameter:}">
	        <eo:AJAXUploader id="AJAXUploader1" runat="server" Width="400px" TempFileLocation="~/App_Date/eo_upload" MaxDataSize="30000"
		        Rows="2" AutoPostBack="True"></eo:AJAXUploader>
	        <asp:Label id="lblResult" Runat="server"></asp:Label>
        </eo:CallbackPanel>

        </div> 
    
    <div>
        
       
        <asp:UpdatePanel ID="UpdatePanel1" runat="server">
            <ContentTemplate>
            <div id="dataEntry" >
                <table >
                    <tr>
                        <td>
                           
                            <asp:Label ID="Label1" runat="server" CssClass="standard-text" 
                                Text="Contact Name*:"></asp:Label>
                        </td>
                        <td>
                           
                            <asp:TextBox ID="TextBoxContactName" runat="server" CssClass="standard-text" 
                                Width="239px"></asp:TextBox>
                        </td>
                       
                        <td>
                            <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" 
                                ControlToValidate="TextBoxContactName" CssClass="standard-text" 
                                ErrorMessage="* Contact Name is a required value." SetFocusOnError="True">*</asp:RequiredFieldValidator>
                        </td>
                       
                    </tr>
                    <tr>
                        <td>
                            
                            <asp:Label ID="Label9" runat="server" CssClass="standard-text" 
                                Text="Contact Email:"></asp:Label>
                        </td>
                        <td>
                            
                            <asp:TextBox ID="TextBoxContactEmail" runat="server" CssClass="standard-text" 
                                Width="237px"></asp:TextBox>
                        </td>
                       
                        <td>
                             </td>
                       
                    </tr>
                    <tr>
                        <td>
                            <asp:Label ID="Label2" runat="server" CssClass="standard-text" Text="Title*:"></asp:Label>
                        </td>
                        <td>
                            <asp:TextBox ID="TextBoxTitle" runat="server" Width="239px"></asp:TextBox>
                        </td>
                        <td>
                            <asp:Label ID="Label3" runat="server" CssClass="standard-text" 
                                Text="(Please provide a descriptive title for your file)"></asp:Label>
                            <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" 
                                ControlToValidate="TextBoxTitle" CssClass="standard-text" 
                                ErrorMessage="* Title is a required value.">*</asp:RequiredFieldValidator>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            
                            <asp:Label ID="Label4" runat="server" CssClass="standard-text" 
                                Text="Facility*:"></asp:Label>
                        </td>
                        <td colspan="2">
                            
                            <asp:DropDownList ID="DropDownListFacility" runat="server" 
                                CssClass="standard-text">
                            </asp:DropDownList>
                            <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" 
                                ControlToValidate="DropDownListFacility" CssClass="standard-text" 
                                ErrorMessage="* Facility is a required value." InitialValue="0" 
                                SetFocusOnError="True">*</asp:RequiredFieldValidator>
                        </td>
                       
                        <td>
                             </td>
                       
                    </tr>
                    <tr>
                        <td>
                            <asp:Label ID="Label5" runat="server" CssClass="standard-text" 
                                Text="Type of Data*:"></asp:Label>
                        </td>
                        <td colspan="1">
                            <asp:DropDownList ID="DropDownListTypeData" runat="server" 
                                CssClass="standard-text" DataSourceID="LinqDataSource2" 
                                DataTextField="Description" DataValueField="DataTypeID" 
                                AppendDataBoundItems="true" Width="239px" >
                              <asp:ListItem Text="Select the Type of Data..." Value="0" /> 
                            </asp:DropDownList>
                            <asp:LinqDataSource ID="LinqDataSource2" runat="server" 
                                ContextTypeName="HBIFileUploaderDataContext" 
                                Select="new (Description, DataTypeID, Active)" TableName="DataTypes" 
                                Where="Active == @Active">
                                <WhereParameters>
                                    <asp:Parameter DefaultValue="true" Name="Active" Type="Boolean" />
                                </WhereParameters>
                            </asp:LinqDataSource>
                        </td>
                        <td>
                            <asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server" 
                                ControlToValidate="DropDownListTypeData" CssClass="standard-text" 
                                ErrorMessage="* Type of Data is a required value." InitialValue="0">*</asp:RequiredFieldValidator>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            <asp:Label ID="Label6" runat="server" Text="Data Source*:"></asp:Label>
                        </td>
                        <td colspan="1">
                            <asp:DropDownList ID="DropDownListDataSource" runat="server" 
                                CssClass="standard-text" DataSourceID="LinqDataSource3" 
                                DataTextField="Description" DataValueField="DataSourceID" 
                                AppendDataBoundItems="true" Width="239px" >
                              <asp:ListItem Text="Select a Data Source..." Value="0" /> 
                            </asp:DropDownList>
                            <asp:LinqDataSource ID="LinqDataSource3" runat="server" 
                                ContextTypeName="HBIFileUploaderDataContext" 
                                Select="new (DataSourceID, Description, Active)" TableName="DataSources" 
                                Where="Active == @Active">
                                <WhereParameters>
                                    <asp:Parameter DefaultValue="true" Name="Active" Type="Boolean" />
                                </WhereParameters>
                            </asp:LinqDataSource>
                        </td>
                        <td>
                            <asp:RequiredFieldValidator ID="RequiredFieldValidator5" runat="server" 
                                ControlToValidate="DropDownListDataSource" CssClass="standard-text" 
                                ErrorMessage="* Data Source is a required value." InitialValue="0">*</asp:RequiredFieldValidator>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            <asp:Label ID="Label7" runat="server" CssClass="standard-text" 
                                Text="Description:"></asp:Label>
                        </td>
                        <td colspan="1">
                            <asp:TextBox ID="TextBoxDescription" runat="server" CssClass="standard-text" 
                                TextMode="MultiLine" Width="239px" Height="49px"></asp:TextBox>
                        </td>
                        <td>
                             </td>
                    </tr>
                    <tr>
                        <td>
                             </td>
                        <td colspan="1">
                            <asp:Button ID="ButtonSubmit" runat="server" onclick="ButtonSubmit_Click" 
                                Text="Submit" />
                        </td>
                        <td>
                            <asp:Label ID="LabelAcknMessage" runat="server" CssClass="standard-text" 
                                ForeColor="Blue"></asp:Label>
                        </td>
                    </tr>
                    <tr>
                        <td colspan="3">
                            <asp:ValidationSummary ID="ValidationSummary1" runat="server" 
                                CssClass="standard-text" DisplayMode="List" />
                        </td>
                        <td >
                             </td>
                        <td>
                             </td>
                    </tr>
                </table>
             </div>
                
            </ContentTemplate>
        </asp:UpdatePanel>
     
    </div>
    
</asp:Content>
eo_support
Posted: Thursday, January 8, 2009 9:06:15 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,089
Hi,

I am sorry that I wasn't clear in my previous post. We usually need to run the page in order to look into the problem, so when we need a page that can reproduce the problem, we need a page that we can run in our test environment and see the problem, this not only ensures that the problem is within the page and not somewhere else, but also enables us to verify whatever solution that we may come up for you. Obviously without your master page or any related data, we are unable to run your page. So would you be able separate the problem to an independent test page for us?

Thanks!
Dennis
Posted: Thursday, January 8, 2009 10:09:35 AM
Rank: Newbie
Groups: Member

Joined: 1/8/2009
Posts: 3
Good Suggestion. I have built a simple project and can recreate the issue. It breaks as soon as I add the master file.

Can zip and email you the VS2008 project.

Thanks!
eo_support
Posted: Thursday, January 8, 2009 10:12:51 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,089
Hi,

We have sent you a private message as to where to send the samples. Please also include step by step instructions on how to reproduce the problem.

Thanks!
eo_support
Posted: Thursday, January 8, 2009 12:10:51 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,089
Hi,

We have looked into the sample project that you sent to us. The issue is caused by your style sheet. In your Default.aspx, you have:

StylesheetTheme="MSN_Blue"

In the theme's default.css, you have various CSS rules that apply to table, table header and table cell respectively. Since our uploader uses table as well, those rules are applied to elements created by the uploader too. This caused the various misalignments and eventually the problems you observed.

In order to fix the problem, you must make sure that your style sheet only applies to the intended DHTML elements. There are various ways to do so. The most obviously, but might also be most difficult way is to use class name selector instead of element selector. More effective solutions can be achieved but it all comes down to how you define and apply the style selectors. You can find more information about different type of selector at here:

http://www.w3.org/TR/CSS2/selector.html

Hope this helps.

Thanks!


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.