Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
BOOK: ASP.NET Website Programming Problem-Design-Solution
This is the forum to discuss the Wrox book ASP.NET Website Programming: Problem - Design - Solution, Visual Basic .NET Edition by Marco Bellinaso, Kevin Hoffman; ISBN: 9780764543869
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: ASP.NET Website Programming Problem-Design-Solution section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
 
 
Thread Tools Display Modes
  #1 (permalink)  
Old March 28th, 2011, 03:40 PM
Registered User
 
Join Date: Mar 2011
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default ajax load take alot time in sample action

Hello everybody.

i have problem with ajax load is take more than 15 second for sample action i don't know why load more than 15 second, i will put between your hand example with coding please any one have any soluation tell me I will be grateful.

check example in the link blow:

http://test.clientnshosting.net

when click For Sale or For Rent button just chnage style and save Session,this code style :
Code:
.BtnSearchupSale {
    background-image: url("media/btnupsale.png");
    background-repeat: no-repeat;
    border-bottom-color: -moz-use-text-color;
    border-bottom-style: none;
    border-bottom-width: 0;
    border-top-color: -moz-use-text-color;
    border-top-style: none;
    border-top-width: 0;
    color: #f7841b;
    cursor: pointer;
    font-family: Arial,Helvetica,sans-serif;
    font-size: 22px;
    font-weight: bold;
    height: 63px;
    padding-right: 21px;
    width: 214px;
    margin-top:10px;
}
.BtnSearchdownSale {
    background-image: url("media/btndownsale.png");
    background-repeat: no-repeat;
    border-bottom-color: -moz-use-text-color;
    border-bottom-style: none;
    border-bottom-width: 0;
    border-top-color: -moz-use-text-color;
    border-top-style: none;
    border-top-width: 0;
    color: #4e7502;
    cursor: pointer;
    font-family: Arial,Helvetica,sans-serif;
    font-size: 16px;
    font-weight: bold;
    height: 59px;
    text-align:center;
    width: 139px;
    margin-top:10px;
}
action button to change style and save session code is:
Code:
 <asp:Button ID="btnforsale" runat="server" BorderStyle="None" Text="For Sale" CssClass="BtnSearchdownSale" onclick="btnforsale_Click" />

  protected void btnforsale_Click(object sender, EventArgs e)
    {
        lblprice.Text = "Price";
        btnforsale.CssClass = "BtnSearchupSale";
        btnforrent.CssClass = "BtnSearchdownRent";
        btnforsaleorrent.CssClass = "BtnSearchdownSaleOrRent";
        Label5.Text = "Properties for sale in jordan";
        Session["ddlOfferTypeSearch1"] = "3";
        upPropertySearch.Update();
        upPropertyList.Update();
    }
look at the time load ajax , when use page on localhost is very speed i don't see loading image, but when upload on server windows is so slow, and i am check other server also slow.
i don't know if ajax is take this time or there are problem.

another sample for ajax load when select Department go to database and get category for department also need more than 15 second. also on localhost is very fast fetch data from database
when upload on server is so slow as sample in this link :http://test.clientnshosting.net/default.aspx
look at code fetch data from database (i am use stored procdure)
Code:
protected void lnkRes_Click(object sender, EventArgs e)
    {
        lbl_type.Text = "Residential";
        lblnote.Text = "";
        clsCategory objcate= new clsCategory();
        DataTable dt = new DataTable();
        objcate.Dept_ID = 1;
        if (objcate.GetCategory(null, null, dt) != -1)
        {
            GVCate.DataSource = dt;
            GVCate.DataBind();
        }
        upPropertyList.Update();
    }
i wish if any one give me soluation, becuase is very bad programmer need alot time.

with best regards
Ahmad Ali
 


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Calling the "Regsiter" action method using AJAX (page 122) lagonave BOOK: Professional ASP.NET MVC 2 24 December 12th, 2012 08:37 AM
JQuery for ASP.NET sample code doesn't load in VS 2008 Aging Hippie All Other Wrox Books 3 August 3rd, 2010 12:24 PM
ASP.NET Ajax client-side framework failed to load mkarmali BOOK: ASP.NET 3.5 Website Programming Problem Design Solution 1 April 6th, 2010 10:01 AM
500 - Internal server error. ONLY when data received is alot RinoDM Classic ASP Databases 1 February 3rd, 2010 04:55 PM
Sample Ajax Book vigaluna Ajax 1 March 22nd, 2007 06:21 PM



All times are GMT -4. The time now is 07:16 PM.


Powered by vBulletin®
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.