いリセットASP.Net AJAXでのカスケードドロップダウン制御(クライアント側)

StackOverflow https://stackoverflow.com/questions/116564

質問

のカスケードドロップダウンの制作を除きることができないの姿をリセットをドロップダウンのクライアント側(Javascript)

私の設定はこのようになっ

DD1
DD2
DD3
DD4

DD に依存前 DD 利用webserviceを負荷します。

変更について DD3 したいリセット DD4 で前の選択をご利用いただけます。

で実現できるのだろうか。また清算価値を支え隠れた入力制御(cddTest_ClientState)は無駄にな

つくばイノベーション

役に立ちましたか?

解決

ここでは溶液

<asp:DropDownList ID="dd1" runat="server" onChange="ondd1ChangeHandler(this)>
</asp:DropDownList>
<asp:DropDownList ID="dd2" runat="server">
</asp:DropDownList>
<cc1:CascadingDropDown ID="cdd2" runat="server" Category="Cat1"
    ParentControlID="dd1" PromptText="(Select Option)" ServiceMethod="GetOptions"
    ServicePath="Services/GetOptions.asmx" TargetControlID="dd2">
</cc1:CascadingDropDown>

<script type='text/javascript>
    function ondd1ChangeHandler(dd){
        var dd2=$get('dd2');
        dd2.selectedIndex=0;
        var cdd=$find('cdd2');
        if(cdd!=null){
            cdd.set_SelectedValue('','');
            cdd._onParentChange(null,false);
        }
    }
</script>

武器agiは、dexで下がらないboxerぐ

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top