I have 6 cdd structured as follows
cdd 1 (top most)
cdd 2 -> parent = 1
cdd 3 -> parent = 2
cdd 4 -> parent = 2
cdd 5 -> parent = 2
cdd 6 -> parent = 5
As you can see 3, 4 & 5 share the same parent. This works fine and all drop down populate = great ! When I add 6, where the parent is one of the children that share a parent, IE does not respond. If I click on the page I get (Not Responding) in the title bar and if I keep clicking I get the popup "The script is causing internet explorer to run slowly do you want to abort the script".
Code is here...
<ajaxToolKit:CascadingDropDownID="cddState"runat="server"TargetControlID="ddState"
Category="State"LoadingText="[Loading states...]"PromptText="-Please Select-"
ServiceMethod="GetTechnicalComboValues"ServicePath="Services\CascadeCombo.asmx"
Enabled="True">
</ajaxToolKit:CascadingDropDown>
<ajaxToolKit:CascadingDropDownID="cddSuburb"runat="server"TargetControlID="ddSuburb"
Category="Suburb"LoadingText="[Loading suburbs...]"PromptText="-Please Select-"
ServiceMethod="GetTechnicalComboValues"ServicePath="Services\CascadeCombo.asmx"
Enabled="True"ParentControlID="ddState">
</ajaxToolKit:CascadingDropDown>
<ajaxToolKit:CascadingDropDownID="cddHomeDrive"runat="server"TargetControlID="ddHomeDrive"
Category="HomeDrive"LoadingText="[Loading drives...]"PromptText="-Please Select-"
ServiceMethod="GetTechnicalComboValues"ServicePath="Services\CascadeCombo.asmx"
Enabled="True"ParentControlID="ddSuburb">
</ajaxToolKit:CascadingDropDown>
<ajaxToolKit:CascadingDropDownID="cddProfilePath"runat="server"TargetControlID="ddprofilepath"
Category="ProfilePath"LoadingText="[Loading paths...]"PromptText="-Please Select-"
ServiceMethod="GetTechnicalComboValues"ServicePath="Services\CascadeCombo.asmx"
Enabled="True"ParentControlID="ddSuburb">
</ajaxToolKit:CascadingDropDown>
<ajaxToolKit:CascadingDropDownID="cddExchangeServer"runat="server"TargetControlID="ddExchangeServer"
Category="ExchangeServer"LoadingText="[Loading servers...]"PromptText="-Please Select-"
ServiceMethod="GetTechnicalComboValues"ServicePath="Services\CascadeCombo.asmx"
Enabled="True"ParentControlID="ddSuburb">
</ajaxToolKit:CascadingDropDown>
<ajaxToolKit:CascadingDropDownID="cddMailStorageGroup"runat="server"TargetControlID="ddMailStorageGroup"
Category="MailStore"LoadingText="[Loading stores...]"PromptText="-Please Select-"
ServiceMethod="GetTechnicalComboValues"ServicePath="Services\CascadeCombo.asmx"
Enabled="True"ParentControlID="ddExchangeServer">
</ajaxToolKit:CascadingDropDown>
Thanks
Was this ever resolved? I'm having a very similar problem.
Here's my scenario:
cdd1 (top-most)
cdd2 -> parent = 1
cdd3 -> parent = 1
cdd4 -> parent = 1
cdd5 -> parent = 4
Now I get the same problem as you: IE6 unresponsive and later the message "A script on this page is causing Internet Explorer to run slowly. If it continues to run, your computer may become unresponsive. Do you want to abort the script?".
Note that I don't have this issue if I remove cdd5 (leaving 1, 2, 3, 4) or if I remove cdd2 (leaving 1, 3, 4, 5) or if I remove cdd3 (leaving 1, 2, 4, 5). So it appears that what's common with your scenario is that if you have three CascadingDropDowns dependent on a given CDD and another CDD dependent on one of the three level2 CDDs, the web page hangs with the above errors.
Thanks for any insight you can give.
-Wayne
Yes I resoved this (by workaround), I apologise for not updating my post.
It comes down to the order the cascading controls appear in the markup (note: not the combo boxes BUT the cascading extenders themselves).
What you need to is to position cdd4 above cdd3 so you end up with this:
cdd1 (top-most)
cdd2 -> parent = 1
cdd4 -> parent = 1
cdd3 -> parent = 1
cdd5 -> parent = 4
As I indicated above the change is only how they appear in the markup. Your cascading relationships and combo boxes themselves dont change. I hope this makes sense.
This sent me crazy... with no replies to my original post it was only by fluke that I discovered this behaviour.
I hope you have success.
Wow! It works.
Thanks very much for the help!
Did you experience any other gotchas using the CascadingDropDownExtender? Initially, I was planning on using standard asp DropDownLists with Ajax UpdatePanels, instead of the CascadingDropDownExtender. However, this is not possible in a FormView if you name your controls the same in both InsertItemTemplate and UpdateItemTemplate. (Here's a post on this problem: http://forums.asp.net/p/1058745/1570069.aspx) I had decided that if I couldn't get the CascadingDropDownExtender to work, I'd just use the UpdatePanels in the template most used for this app. If you know of any other issues with this extender, I'd appreciate finding out. Seems like your scenario might be somewhat similar to mine. I assume you're doing inserts and updates with the dropdowns on which you had the problem?
Thanks again for the help!
The only other problem I had was populating a cascading set via Javascript. There are a number of articles on this but I couldn't get it to work.
The scenario I had was select a State and then select a suburb. The suburb would populate based on the state selected = standard stuff.
I had a copy function that copied these values from another record and I wanted to use Javascript to avoid a postback. I could set the state value but I couldn't set the suburb value.
No comments:
Post a Comment