Showing posts with label error. Show all posts
Showing posts with label error. Show all posts

Wednesday, March 28, 2012

UpdateProgress throws javascript error when contained in a Panel with visible = false

If you put a UpdateProgress control inside a Panel control with visible=false, you will get a javascript error that is cannot find the elements used for the update progress functionality.

Anyone, seen this before and know of a workaround?

I get the same result in a MultiView when the UpdateProgress control is contained in a view that is not the current view.

Thanks,

Ryan

When you set Visible equal to false the HTML contained therein does not get rendered at all. You shouldn't need to explicitly hide the UpdatePanel as it should hide itself unless an Atlas postback is in progress.

If you do need to hid it, set the style of the panel to "display: none" and leave it visible. That way the HTML will be rendered but not shown on screen.


Thanks for the suggestion on display: none. This will work for Panel controls, but it won't work for pages using the MultiView control. I guess I'll have to get rid of MultiView and create several separate panels wnd manually control which one is shown and which ones are diplay: none.

Saturday, March 24, 2012

Upgrade error: Could not load file or assembly Microsoft.Web.Extensions, Version=1.0.61025

I have upgraded from Beta 2 to RC1 and followed all of the upgrade instructions, but I'm still getting this error:

Error 26 Could not load file or assembly 'Microsoft.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.

I'm aware that Microsoft.Web.Extensions is now System.Web.Extensions, but I can't find where the old reference is!!!

I have searched all the files in my project for "Microsoft.Web.Extensions" as well as the machine.config. I'm currently searching every file on my hard drive for this reference and still can't find it.

Any ideas?

Thanks,

Still looking for some help...
Do you have the ControlToolkit on your site? We had that error before we updated to the newest toolkit.

I've found you have to move the DLL files form the .NET version folder on the hard drive to the bin folder in the site otherwise they need to be in the GAC.

I'm finding other problems with it. Like [no relevant source code lines] gotta be permissions or something.

Still looking...


I have the same problem and finally found out that the reference to Microsoft.Web.Extensions is in my web.config.

Have to go through and changes all "Microsoft.Web" to "System.Web" (mainly under the<pages><controls> tag).

Upgrade to Beta 1 = New Rating control error

I installed the latest framework and toolkit.

My project was working fine with a wizard control that contained rating controls. I've taken the rating controls out of the wizard template and put them in their own update panel and still receive the error. It's a very strange behavior. If I make a new page and do everything, the rating control works fine. I'm using the latest control and did all the changes required to use the new Beta. After the install, I keep receiving this error when loading the page:

System.InvalidOperationException was unhandled by user code
Message="The TargetControlID of '_RatingExtender' is not valid. The value cannot be null or empty."
Source="Microsoft.Web.Extensions"
StackTrace:
at Microsoft.Web.UI.ExtenderControl.RegisterWithScriptManager()
at Microsoft.Web.UI.ExtenderControl.OnInit(EventArgs e)
at AjaxControlToolkit.ExtenderControlBase.OnInit(EventArgs e) in C:\Program Files\Microsoft ASP.NET\AjaxControlToolkit\AjaxControlToolkit\ExtenderBase\ExtenderControlBase.cs:line 338
at System.Web.UI.Control.InitRecursive(Control namingContainer)
at System.Web.UI.Control.InitRecursive(Control namingContainer)
at System.Web.UI.Control.InitRecursive(Control namingContainer)
at System.Web.UI.Control.AddedControl(Control control, Int32 index)
at System.Web.UI.ControlCollection.Add(Control child)
at Microsoft.Web.UI.UpdatePanel.SingleChildControlCollection.AddSingleChild(Control child)
at Microsoft.Web.UI.UpdatePanel.AddContentTemplateContainer()
at Microsoft.Web.UI.UpdatePanel.CreateContents(Boolean recreate)
at Microsoft.Web.UI.UpdatePanel.OnInit(EventArgs e)
at System.Web.UI.Control.InitRecursive(Control namingContainer)
at System.Web.UI.Control.InitRecursive(Control namingContainer)
at System.Web.UI.Control.InitRecursive(Control namingContainer)
at System.Web.UI.Control.InitRecursive(Control namingContainer)
at System.Web.UI.Control.InitRecursive(Control namingContainer)
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

Thanks

Anyone ? Can you please take a look? I believe others are experiencing something similar with the mentioned TargetControlID.

Thanks


When the project breaks, it breaks at the bold:

/// <summary>
/// On Init we load target properties values and process databinding handlers.
/// </summary>
/// <param name="e"></param>
protected override void OnInit(EventArgs e)
{
if (EnableClientState)
{
CreateClientStateField();
}
// EnsureProfileScriptService(ScriptManager.GetCurrent(Page), true);
Page.PreLoad += new EventHandler(Page_PreLoad);
base.OnInit(e);
}


Please reply with acomplete, self-contained sample page that demonstrates the problem. Thank you!

In my case the problem occures when I specify the rating control in the skin file.

Skinfile:

<

ajaxToolkit:Ratingrunat="server"StarCssClass="ratingStar"WaitingStarCssClass="savedRatingStar"FilledStarCssClass="filledRatingStar"EmptyStarCssClass="emptyRatingStar"/>
Good to know! Do you have a complete, self-contained sample we can play with?

Just add the following 2 lines in the Default.skin file of the Ajax Control Toolkit SampleWebSite:

<%@.RegisterAssembly="AjaxControlToolkit"Namespace="AjaxControlToolkit"TagPrefix="ajaxToolkit" %>
<ajaxToolkit:Ratingrunat="server"StarCssClass="ratingStar"WaitingStarCssClass="savedRatingStar"FilledStarCssClass="filledRatingStar"EmptyStarCssClass="emptyRatingStar"/>

Then try to open the Rating sample of the SampleWebSite.


The SampleWebSite doesn't have a Default.skin file - might there be something else going on here that's causing issues?

upgraded to new March ctp, having 2 menu creates js error?

Hi I just upgraded to march ctp...

1. Are there any scripts? I saw in another topic post talk about copying the new scripts, but I thought its all in the dll now, http module to provide the javascript right? there are no .js files right?

2. I have 2 menus.. i am getting this error often (not always) upon moving my mouse off the menu/tab:

A Runtime Error has occurred.
Do you wish to Debug?

Line 220
Error: '0.cells' is null or not an object

I think it has something to do with the "Menu_Unhover" function for the menus, but I am not sure

First menu is in masterpage, second menu is tabbed and on a page that uses the ScriptManager and UpdatePanel

bump - this has been mentioned a few times.

It generates that error with a menu in a updatepanel.

If anyone knows how to fix the javascript to prevent this error as a workaround let me know.


I have not thoroughly tested, but I did this:

protected void Page_Load(object sender, EventArgs e)
{
//ScriptManager1.RegisterAsyncPostBackControl(ResumeWizardTabbedMenu);
ScriptManager1.RegisterControl(ResumeWizardTabbedMenu);
}

The idea came from this post:

http://forums.asp.net/1223652/ShowPost.aspx
ScriptManager1.RegisterAsyncPostbackControl(Menu1);

-chau


Hi everyone,

The Menu hover issue will be fixed in the April CTP of Atlas (soon to be released!).

Thanks,

Eilon

Upgraded to AJAX Beta 2 - Now getting IE error Operation Aborted

...and page fails to load. If you refresh all is ok.

All I have used is Autoextender and updatepanel on the page with a master page.

Any ideas what this bug is and how to fix it?

MasterPage/ContentPage Scenarios
You may have a ScriptManager on your master page, but you may want to add additional script or service references in your content page. However, you can only have one ScriptManager on your page. Therefore we have the accompanying ScriptManagerProxy control.
<asp:Content ...>
<atlas:ScriptManagerProxy runat="server" id="scriptManagerProxy">
...
</atlas:ScriptManagerProxy>
</asp:Content

hello.

difficult to say what's happening without getting more info about the error...


I also upgraded to Beta 2 and now getting this error : but it is intermitant and really dont know what bit of code is doing it.

www.destinationrussia.com

Any ideas?


Hi,

I installed Ajax Beta 2 and future CTP Novemner in my PC.I could accesswww.destinationrussia.com through IE 7.0,FireFox and Opera and found the web page was loaded correctly for the first time.There are no any browser errors happened.Can you post some error message here?


Jasson_King:

Hi,

I installed Ajax Beta 2 and future CTP Novemner in my PC.I could accesswww.destinationrussia.com through IE 7.0,FireFox and Opera and found the web page was loaded correctly for the first time.There are no any browser errors happened.Can you post some error message here?

its a very intermittant error... i am driving myself crazy dealing with it to, as i cannot replicate it on demand

Luis Abreu:

hello.

difficult to say what's happening without getting more info about the error...

Want more info?
http://forums.asp.net/thread/1471506.aspx
http://weblogs.asp.net/infinitiesloop/archive/2006/11/02/Dealing-with-IE-_2600_quot_3B00_Operation-Aborted_2600_quot_3B002E00_-Or_2C00_-how-to-Crash-IE.aspx
http://www.ryangrant.net/archives/internet-explorer-cannot-open-the-internet-site-operation-aborted-google-map-api/

This error is indeed a tough one to track down

Wednesday, March 21, 2012

urlrewriter + ajax + magicajax : Httpmodule error

The MagicAjax HttpModule is not included in web.config. Add [<httpModules><add name="MagicAjax" type="MagicAjax.MagicAjaxModule, MagicAjax" /></httpModules>] inside the <system.web> section.

Description:An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details:MagicAjax.MagicAjaxException: The MagicAjax HttpModule is not included in web.config. Add [<httpModules><add name="MagicAjax" type="MagicAjax.MagicAjaxModule, MagicAjax" /></httpModules>] inside the <system.web> section.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.


Stack Trace:

[MagicAjaxException: The MagicAjax HttpModule is not included in web.config. Add [<httpModules><add name="MagicAjax" type="MagicAjax.MagicAjaxModule, MagicAjax" /></httpModules>] inside the <system.web> section.] MagicAjax.MagicAjaxContext.get_Current() +123 MagicAjax.UI.AjaxControl.SetAjaxIntrinsics() +15 MagicAjax.UI.Controls.AjaxPanel.OnLoad(EventArgs e) +17 System.Web.UI.Control.LoadRecursive() +35 System.Web.UI.Control.LoadRecursive() +98 System.Web.UI.Control.LoadRecursive() +98 System.Web.UI.Control.LoadRecursive() +98 System.Web.UI.Control.LoadRecursive() +98 System.Web.UI.Page.ProcessRequestMain() +731

may be this is not right place, but i have posted the error above every topic not getting solution , and also may be its due to conflict between ajax and magicajax so , hoping to get solution, i m posting in this forum also. Please help , its urgent...

regards,

max

Do you have the ConfigItem in the <httpModules/> as the following codes? If not,try to add it.
<system.web>
<httpModules>
??????<add name="WebResourceCompression" type="Microsoft.Web.Handlers.WebResourceCompressionModule, Microsoft.Web.Extensions, ???????Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
??????<add name="ScriptModule" type="Microsoft.Web.UI.ScriptModule, Microsoft.Web.Extensions, Version=1.0.61025.0, Culture=neutral, ???????PublicKeyToken=31bf3856ad364e35"/>
??????<add name="MagicAjax" type="MagicAjax.MagicAjaxModule, MagicAjax" />
</httpModules>
</system.web>
Wish the above can help you.

I'm facing a problem the same error:

The MagicAjax HttpModule is not included in web.config. Add [<httpModules><add name="MagicAjax" type="MagicAjax.MagicAjaxModule, MagicAjax" /></httpModules>] inside the <system.web> section.

Of course, I have already added this section to the web.config file, but the error keeps display.

Now, I face this case when I try to run the application on Windows Vista Operating System (Ultimate Edition) with IIS 7.0, while I don't get any error if I run and host the application on Windows XP with IIS 6.0.

I think its some configuration problem, but unfortunately I couldn't find any solution for that on the Internet. Some people said its related to Server.Transfer and Response.Redirect. In my application I'm using Response.Redirect as I don't think its the reason behind this error. Any why, I hope that you will be able to support me and help with my case because I need to dimonstrate the project very soon on the Windows Vista Operating System.

I appretiat your help and support.

Thanks,

UrlRewriting, CascadingDropDown and "*" verb

Hi,

I use urlrewriting. In IIS settings contains "*" verb.
When I use CascadingDropDown there is an error of "Method error 405".
When I delete "*" verb - all is OK.

How to decide a problem without the delete of "*"?

Your URL rewriter is probably interfering with ASP.NET AJAX's handler for web service traffic.

Hello,

thank you for reply.

For rapid solution with MS ASP.NET AJAX I use jointly Anthem.NET AJAX. DropDownList control in Anthem.NET AJAX is working without web service (data is loading directly from DataSet). These two libraries is working jointly without conflicts.


I had the same problem I have resolved it. It is a problem/bug with IIS 5, look here:http://forums.asp.net/t/1123124.aspx

You may also add form extender as described here:http://forums.asp.net/t/1129701.aspx.

This is the code you need:

Ok, I have fixed it. It requires this code. Seems like this is a bug in IIS 5...It is not stripping PathInfo correctly before handling request to ASP.NET

privatevoid OnBeginRequest(object sender,EventArgs e)

{

HttpApplication app = senderasHttpApplication;

HttpContext context = app.Context;

string path = context.Request.Path;

int aspx = path.IndexOf(".aspx/",StringComparison.OrdinalIgnoreCase);if (aspx >= 0)

{

context.RewritePath(

path.Substring(0, aspx + 5),

path.Substring(aspx + 5),

context.Request.QueryString.ToString());

return;

}

int asmx = path.IndexOf(".asmx/",StringComparison.OrdinalIgnoreCase);if (asmx >= 0)

context.RewritePath(

path.Substring(0, asmx + 5),

path.Substring(asmx + 5),

context.Request.QueryString.ToString());

}

}

Use a menu control in updatepanel

that occurs a javascript error when click another tab: "0.cells" is null or not an object.

who can help me? thanks.

The menu control is not compatible with partial-page updates and can't be used inside a UpdatePanel.


what can i do if i want to implement this function?thx.
Could you run this in JS debugger and post a snippet of affected JS.. I vaguely remember dealing with this issue and it might allow us to see what is exactly happening

did quick google

and found e.g. this

http://forums.asp.net/thread/1485169.aspx


thanks for your information, i read a blog and using this method it works well.

http://mcosier.blogspot.com/2006/12/0cells-is-null-or-not-object-aspnet-20.html

but i have a problem that:

it seems that using AsyncPostBackTrigger can't change the StaticSelectedStyle after i clicked another menuitem?

thanks.


I've been using this piece of javascript to go around the menu problem:

var oldMenu_HideItems = Menu_HideItems;if(oldMenu_HideItems){Menu_HideItems = function(items){if (!items || ((typeof(items.tagName) =="undefined") && (items instanceof Event))) { items = __rootMenuItem; }if(items && items.rows && items.rows.length == 0){ items.insertRow(0); }return oldMenu_HideItems(items);} }
I got it from the asp:menu javascript code and I hook it to "patch" the problem.
Adding it to a page where a menu resides makes the javascript error go away. 

This one works great for me.

Thank you very very much.Big Smile

Great


it is working.. Smile Thank you for your great solutions.

thanks t0yBig Smile

i tryed it.and i dident give that error.

thanks again.


Dear sir

can you please tell me where to put this code in what event, name of the function it is very imp.

thank you,

please advise what to do.


This piece of Javascript has saved me hours of googling! Awesome work buddy and thanks heaps!

See for more info , which controls are not compatable with UpdatePanel

http://ajax.asp.net/docs/overview/UpdatePanelOverview.aspx


I cannot figure out how to use this fix. I put this script in my page and I'm still getting the 0.cells is nothing error.

How do I hook this up?

Thanks!


Have you tried the solution thatt0y provided..

It's working..Smile