I have downloaded AjaxToolkit Samples from Ajax.asp.net, it also gives me Sys undefined. So it is a known problem and either it has to somthing to do with my installation or problem is not solved yet by the Ajax Developement Team.
I have the same thing also, but the strange think is that some pages (in the same application, same directory) always work fine and others always give the 'Sys' undefined error. So I took a look at the HTML source
The pages that work fine all contain the following text:
// If script tag is found add reference to ScriptResource before it
result = output.Substring(0, locationStart - 1);
result += "<script src=\"/ScriptResource.axd?d=-muoDG4AZqg8O1bZJbSaPP6N61De8BkdhQUJPkBdEZwXXi8KfuPry3zIuHDwWRdPaUiDdZAuiFrPrPPO4OkpRXAuuaoAd9VB9b4LTDICmYM1&t=633022952116725360\" type=\"text/javascript\"></script>\n";
Ok, i have been investigating a little bit and came up with a solucion (at least for scenario)
Since my Application works on XP and on Windows 2000 using Firefox, i realized that this problem had something to do with Internet Explorer on Windows 2000 only.
So I took a brand new computer and installed Windows 2000 SP4 (with no patches at all) on it. When I visited Windows Update site it told me that my operative system needed 45 patches.
Instead of applying all of them. I just applied two:
-Internet Explorer 6 SP1
-KB912812 [1]
And it was solved. No more "Sys is undefined on any page".
As a final conclusion, i have realized that Ajax.net framework is somehow ready for intranet application since then you can have some control over which operative systems are running and the patches installed on them. But its not ready for internet applications.
Hope this helps
Cheers.
[1] This patch is available here: http://www.microsoft.com/downloads/details.aspx?familyid=033C41E1-2B36-4696-987A-099FC57E0129&displaylang=en
Ok, i have been investigating a little bit and came up with a solucion (at least for scenario)
Since my Application works on XP and on Windows 2000 using Firefox, i realized that this problem had something to do with Internet Explorer on Windows 2000 only.
So I took a brand new computer and installed Windows 2000 SP4 (with no patches at all) on it. When I visited Windows Update site it told me that my operative system needed 45 patches.
Instead of applying all of them. I just applied two:
-Internet Explorer 6 SP1
-KB912812 [1]
And it was solved. No more "Sys is undefined on any page".
As a final conclusion, i have realized that Ajax.net framework is somehow ready for intranet application since then you can have some control over which operative systems are running and the patches installed on them. But its not ready for internet applications.
Hope this helps
Cheers.
[1] This patch is available here: http://www.microsoft.com/downloads/details.aspx?familyid=033C41E1-2B36-4696-987A-099FC57E0129&displaylang=en
Yes, I downloaded the patch and it simply start working, No Sys undefined errors. But my website will not work on those PCs with Window 2000 without this patch. It is very disappointing. I will look for another way.
If I create an AJAX-Enabled Web Application from scratch, it works in both FF and IE. However, my main application works with FF2, but not IE6. I get a series of "Syntax Error"s then one or two "Sys is undefined" errors when I use IE6.
I'm running XPSP2, IIS5, VS2005 and AJAX 1.0
The usual explanation is that the client files are coming across compressed and that I should fire up Fiddler and see what I'm getting. This is what I get:
That doesn't look compressed to me, unless Fiddler is silently expanding it.
I don't think it's anything in web.config, either. If I take the web.config from the template project and use it in the main project, the errors remain.
vishal2006
Member
39 Points
15 Posts
Re: Sys undefined is only on IE but not FireFox...
Dec 21, 2006 10:14 AM|LINK
I have downloaded AjaxToolkit Samples from Ajax.asp.net, it also gives me Sys undefined. So it is a known problem and either it has to somthing to do with my installation or problem is not solved yet by the Ajax Developement Team.
Rookie1
Member
30 Points
9 Posts
Re: Sys undefined is only on IE but not FireFox...
Dec 21, 2006 11:24 AM|LINK
Guntar
Member
2 Points
1 Post
Re: Sys undefined is only on IE but not FireFox...
Dec 21, 2006 02:16 PM|LINK
I have the same thing also, but the strange think is that some pages (in the same application, same directory) always work fine and others always give the 'Sys' undefined error. So I took a look at the HTML source
The pages that work fine all contain the following text:
<script src="/ScriptResource.axd?d=-muoDG4AZqg8O1bZJbSaPP6N61De8BkdhQUJPkBdEZwXXi8KfuPry3zIuHDwWRdPaUiDdZAuiFrPrPPO4OkpRXAuuaoAd9VB9b4LTDICmYM1&t=633022952116725360" type="text/javascript"></script>
Entering ScriptResource.axd as URL does return a script file, so that works fine.
The problem is that on some pages this line is not included. Why is this section not rendered for certain pages?
I have a workaround, but this is not serious code:
protected override void Render(HtmlTextWriter writer)
{
System.IO.StringWriter stringWriter = new System.IO.StringWriter();
HtmlTextWriter localWriter = new HtmlTextWriter(stringWriter);
// Render HTML
base.Render(localWriter);
// Get HTML string
string result;
string output = stringWriter.ToString();
// Search for first script tag
string searchString = "<script";
int locationStart = output.IndexOf(searchString);
if (locationStart > -1)
{
// If script tag is found add reference to ScriptResource before it
result = output.Substring(0, locationStart - 1);
result += "<script src=\"/ScriptResource.axd?d=-muoDG4AZqg8O1bZJbSaPP6N61De8BkdhQUJPkBdEZwXXi8KfuPry3zIuHDwWRdPaUiDdZAuiFrPrPPO4OkpRXAuuaoAd9VB9b4LTDICmYM1&t=633022952116725360\" type=\"text/javascript\"></script>\n";
result += output.Substring(locationStart);
}
else
// If script tag is not found, change nothing
result = output;
// Return modified HTML
writer.Write(result);
}
Luis Abreu
All-Star
25674 Points
5369 Posts
MVP
Re: Sys undefined is only on IE but not FireFox...
Dec 21, 2006 02:52 PM|LINK
I'm using this one:
<add verb="GET,HEAD" path="ScriptResource.axd" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" validate="false"/>
btw, which version of iis are you using?
Regards,
Luis Abreu
email: labreu_at_gmail.com
EN blog:http://msmvps.com/blogs/luisabreu
vishal2006
Member
39 Points
15 Posts
Re: Sys undefined is only on IE but not FireFox...
Dec 22, 2006 05:51 AM|LINK
I am using iis 5.1. and Using Windows 2000 Professional,
Internet Explorer 6.0.2800.1106 sp1.
I have tried following code, still not working with Internet explorer. (Firefox works fine).
<add verb="GET,HEAD" path="ScriptResource.axd" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" validate="false"/>.
Regards,
Vishal
Rookie1
Member
30 Points
9 Posts
Re: Sys undefined is only on IE but not FireFox...
Dec 22, 2006 02:04 PM|LINK
Ok, i have been investigating a little bit and came up with a solucion (at least for scenario)
Since my Application works on XP and on Windows 2000 using Firefox, i realized that this problem had something to do with Internet Explorer on Windows 2000 only.
So I took a brand new computer and installed Windows 2000 SP4 (with no patches at all) on it. When I visited Windows Update site it told me that my operative system needed 45 patches.
Instead of applying all of them. I just applied two:
-Internet Explorer 6 SP1
-KB912812 [1]
And it was solved. No more "Sys is undefined on any page".
As a final conclusion, i have realized that Ajax.net framework is somehow ready for intranet application since then you can have some control over which operative systems are running and the patches installed on them. But its not ready for internet applications.
Hope this helps
Cheers.
[1] This patch is available here: http://www.microsoft.com/downloads/details.aspx?familyid=033C41E1-2B36-4696-987A-099FC57E0129&displaylang=en
vishal2006
Member
39 Points
15 Posts
Re: Sys undefined is only on IE but not FireFox...
Dec 26, 2006 03:52 AM|LINK
Yes, I downloaded the patch and it simply start working, No Sys undefined errors. But my website will not work on those PCs with Window 2000 without this patch. It is very disappointing. I will look for another way.
Thanks & Regards
- Vishal
Rookie1
Member
30 Points
9 Posts
Re: Sys undefined is only on IE but not FireFox...
Dec 26, 2006 12:43 PM|LINK
Yes, i totally agree. Please let us know if you find a better workaround.
Regards,
rhockman
Member
8 Points
4 Posts
Re: Sys undefined is only on IE but not FireFox...
Apr 26, 2007 07:43 PM|LINK
If I create an AJAX-Enabled Web Application from scratch, it works in both FF and IE. However, my main application works with FF2, but not IE6. I get a series of "Syntax Error"s then one or two "Sys is undefined" errors when I use IE6.
I'm running XPSP2, IIS5, VS2005 and AJAX 1.0
The usual explanation is that the client files are coming across compressed and that I should fire up Fiddler and see what I'm getting. This is what I get:
That doesn't look compressed to me, unless Fiddler is silently expanding it.
I don't think it's anything in web.config, either. If I take the web.config from the template project and use it in the main project, the errors remain.
--Ron
arnoldmatusz
Member
100 Points
25 Posts
Re: Sys undefined is only on IE but not FireFox...
Apr 26, 2007 09:02 PM|LINK
I was having the same issue and deleting the <system.webserver> tag in the web.config file solved it for me!
www - DreamLab Solutions
Blog - Arnold Matusz's Blog