Last post Apr 04, 2007 09:15 AM by atsofttech
Mar 21, 2007 10:37 AM|VenusBai|LINK
I installed and using the Toolkit in my web site.I am enjoy the cool features , except for one problem : the web page became too big to open,because the script file too large(one file is 255KB).
Yes, I know if a user opened my web page once ,it will be faster ,because the script file will not download again . But I think major visitor will not wait for 1 or 2 min to open my web .
Is any body has the same problem? And is a solution ?
Thanks a lot !
Mar 22, 2007 12:52 AM|kirtid|LINK
Mar 22, 2007 02:12 AM|VenusBai|LINK
Thank you very much Kirtid. The 255KB file is :
I am sorry I did not very understand "Could you try the same with the release bits?" because I am a Chinese :)
The version of the Toolkit I am usring is "1.0.10123.0 "
Do you mean I should use a new version of the Ajax Control Toolkit ?
Mar 22, 2007 02:37 PM|kirtid|LINK
We build the toolkit in 2 flavors: Ship/Release and Debug. The Toolkit ship scripts are smaller in size. If you use the 10301 version of the toolkit the ship scripts are now compressed(comments and safe whitespace is removed). If you open the linked script
file in notepad you will see that this is the ASP.Net AJAX file and not a Toolkit file. You can post questions about perf issues on the asp.net ajax forums.
// Copyright (C) Microsoft Corporation. All rights reserved.
// Microsoft AJAX Framework.
Mar 23, 2007 03:35 AM|VenusBai|LINK
Oh, Yes. You are right kirtid.I will ask Bill Gates this question ,ha ~
Anyway thanks a lot !
Mar 23, 2007 03:58 AM|atsofttech|LINK
I am having same issue and it sees that using AJAX.net slow down the application as well.
Why don't you use other AJAX panel from thrid party?
Mar 23, 2007 08:10 AM|Dennis van de Laar|LINK
You are using the debug library. set in your config file debyg=false or set scriptmode=release in your sciptmanager object.
Hope this helps,
Mar 24, 2007 04:30 AM|atsofttech|LINK
I shall try that
Apr 03, 2007 09:44 AM|cacosta|LINK
Well, let's see.
There are two options:
1- Specify the property "scriptpath" of the ScriptManager object with the path where you have the folder "\System.Web.Extensions" with all the Js files. (Ex: "~/Jscript").
In this case the page will be too big to load in the browser because the files "MicrosoftAjax.js" and "MicrosoftAjaxWebForms.js" will be completely loaded with the page.
If you have the property "scriptmode" = release, then the files will have 80KB plus 20KB. With "scriptmode" = debug the files will have 250KB plus 60KB.
If you have cache for Js in the browser its OK and the first time the page is loaded will take much longer.
Don't forget to include the following line in web.config:
In both cases it will generate a script include with this and it will have always 20KB:
Hope it works for you! For me it's rocking !!!....
Apr 03, 2007 10:06 AM|cacosta|LINK
Just a little correction:
The first time the page is loaded it will always generate JS's with the complete size: 80KB plus 20KB.
In my case, I am working with ScriptManager and UpdatePanel with Async call with just a dropdownlist and a button.
Apr 03, 2007 07:09 PM|porov|LINK
I have the same problem.
Setting debug=false and scriptmode=release doesn't make a big difference. Yes the script files are smaller, but they are still too big for my needs(150kb). My web hosting company doesn't have very fast servers so my pages have to be as small as possible.
My current pages are about 35kb per request(css and images included), so 150kb its just way too much. Is there some way to make these files smaller(say less than 50kb)?
Apr 04, 2007 08:54 AM|cacosta|LINK
Initially my big page was 70KB, then I removed some big combos and I got 30KB with the idea of getting the combos with ajax call.
But, if I have a 30KB page + 80KB js + 20KB js + 20KB webresource.axd, it will total 150KB on the first call.
I hope I can use this with browser cache, but the first call will always be desperately slow.
Apr 04, 2007 09:15 AM|atsofttech|LINK