Showing posts with label beta. Show all posts
Showing posts with label beta. Show all posts

Wednesday, March 28, 2012

Change in behavior of RegisterStartupScript

In Beta 1, it is requried to use the ScriptManager.RegisterStartupScript method, and this method requires that a control that is within the partial update is passed as the first parameter.

All my pages inherit the same BasePage, and I wan't to register a startup script every time a partial update occurs, regardless of where the update is done.

Please change this back so that the Page.ClientScript.RegisterStartupScript method can be used!

Einar

I need a page based RegisterStartupScript as well. I haven't seen anything from Microsoft mentioning that they would bring this back. Is there a way to run Java Script from a class file?

Thanks,

Jennifer


We can't properly support RegisterStartupScript itself since there's no way to know what people registered. However, we're considering an option to allow people to call a new method (or perhaps change an existing method) to register scripts that should always get included in the async post.

Thanks,

Eilon


Thats great news Eilon, crossing my fingers, would simplify things a great deal :-)

By the way, big thanks to the team for all the great sessions in Barcelona last week!

Einar


Eilon,

This would be great. If the RegisterStartupScript of the ScriptManager did not require a reference to a control in an update panel, life would be much easier. Thanks,

Mark

Saturday, March 24, 2012

CascadingDropDown screen flicker

I have loaded the Beta 1.0 Ajax Extensions as well as release 61020 of the Ajax Control Toolkit.

I followed the migration documentation and notice that the CDD controls that I am using cause the entire browser screen to flicker.

This was NOT the case with the previous release. It occurs on the Ajax Control Toolkit demo site as well as in the example project. Postback elimination was one of the primary reasons for my using these controls.

What gives?

Ken J.

It's still not posting back, so that's not the issue. It looks fine to me in IE7, so could you please indicate which browser(s) do/do not exhibit the problem for the demo site athttp://ajax.asp.net/ajaxtoolkit/?

Wednesday, March 21, 2012

CascadingDropDown returns [Method Error 12031] after upgrade to 1.0 Beta

After upgrading from the July CTP to 1.0 Beta all my CascadingDropDown's have stoped working. I only get [Method error 12031] in return an all of them. I hade the same problem when implementing them the first time but I then found the answer in thread 1393072 and referenced threads. This time however I am not able to find anything that helps me. I have tried to migrate my July CTP projekt to a new empty 1.0 Beta project but it doesn't help. Have anyone else hade the same problem?

I am grateful for any suggestions and tips!!

Have you made sure to decorate your service class with this attribute?

[Microsoft.Web.Script.Services.ScriptService()]
public class MyService : WebService
{
...
}


Thanks allot!

Now i works just fine. One can wonder why that line isn't in the walkthrough for CascadingDropDown!


Thanks a lot for that! That's been bugging me all morning. Although I didn't have [Method Error 12031], I had [Method Error 500], this solution still worked for me. It really should be in the walkthrough
I Agree! This should be added RIGHT AWAY!!!

Hey Guys,

Actually there is some documentation and I'll point you to where I found most of my upgrade info. Garbin's recent post on his blog has three links to some very vital information.

http://aspadvice.com/blogs/garbin/archive/2006/10/20/MS-AJAX-v1.0-Beta-and-Ajax-Control-Toolkit-released_2100_.aspx

The CTP-to-Beta whitepaper is where I found the not for adding the ScriptService attribute.

Hope this helps.


The method error 12030 still appears for me when I use the CTP and the specified attribute.

Regards

Vinit


Did you change the return type of your methods that populate your drop downs to return an array of AjaxControlToolkit.CascadingDropDownNameValue objects?

All web methods for child drop downs must have a signature that conforms to the following:

[WebMethod]
public AjaxControlToolkit.CascadingDropDownNameValue[] GetDataForMyChildDropDown(string knownCategoryValues, string category)

You can find this in the CTP-to-Beta whitepaper I believe.


Hiya.

Had the same problem and finally found out why. None of the other things suggested worked. Thanks to Steve Clements for that one... http://geekswithblogs.net/steveclements/archive/2006/10/23/94893.aspx

The web service class either needs

[Microsoft.Web.Script.Services.ScriptService]

or

using Microsoft.Web.Script.Services;

namespace Clm.Web.Services

{

[ScriptService]

publicclassFoo


Your most welcome :)

Steve


Same problem, but using only pagemethods...

What changes do I need to get it working?


Can you post some code?
http://forums.asp.net/thread/1486194.aspx

Hi,

I've run into the same error. However, when I change the line in the webservice.vb file from:

<System.Web.Script.Services.ScriptService ()>'

to:

<Microsoft.Web.Script.Serices.ScriptService ()
I get the error 'Type Microsoft.Web.Script.Serices.ScriptService' is not defined'

The whole "snippet":

<WebService(Namespace:="http://tempuri.org/")> _
<WebServiceBinding(ConformsTo:=WsiProfiles.BasicProfile1_1)> _
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()> _
<System.Web.Script.Services.ScriptService()> _
Public Class CarsService
Inherits System.Web.Services.WebService

Shared _DocumentAs XmlDocument
Shared _lockAs New Object

I'd appreciate any suggestions.
Thanks!

CascadingDropDown not working within EditItemTemplate in Ajax Beta

I had the cascading drop down working fine inside the EditItemTemplate in a gridview with the previous Atlas CTP release. But now it stopped working with Ajax Beta 1.0. Do I need to do something different to make it work again. I tried placing Gridview.Databind() in Page_Load, but that stopped the gridview from updating back to the database.

<EditItemTemplate>

<asp:DropDownListID="ddlBuEdit"runat="server"/>

<ajax:CascadingDropDownID="ccd1"runat="server"

TargetControlID="ddlBuEdit"

Category="BU"

LoadingText="Loading Data..."

PromptText="Select Business Unit"

ServicePath="getSelectionData.asmx"

SelectedValue='<%# Eval("BusinessUnit") %>'

ServiceMethod="getBU"/>

</EditItemTemplate>

Please see if this is relevant:http://forums.asp.net/thread/1441672.aspx.