Click here to Skip to main content
15,917,731 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Please Any Body can check below code, this is not working


XML
<script type="text/javascript" language="javascript">
        $(function () {
            $('#<%=txtKeyWord.ClientID %>').autocomplete({
                source: function (request, response) {
                    $.ajax({
                        url: "WebService.asmx/spGetKeyword",
                        data: "{ 'keyword': '" + request.term + "' }",
                        type: "POST",
                        dataType: "json",
                        contentType: "application/json;charset=utf-8",
                        success: function (result) {
                            response(result.d);
                        },
                        error: function (result) {
                            alert('There is a problem processing your request');
                        }
                    });
                },
                minLength: 0,
                focus: function () {
                    $.ajax({
                        type: "POST",
                        contentType: "application/json; charset=utf-8",
                        data: "{ Iid: '" + $('#<%=txtItemCode.ClientID %>').val() + "'}",
                        url: "WebService.asmx/GetNameFromService",
                        dataType: "json",
                        success: function (data) {
                            $('#<%=txtKeyWord.ClientID %>').val(data.d);
                        }
                    });

                }
            });
        });

    </script>

Help me If any one know
Thanks
Bajid
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900