Now I have a aspx page to show the department employee list. At the above of the page is the query section in which I can choose a department from a dropdownlist and a textbox for typing employee name. Since the signature of the autocomplete controlwebserviceis
"public string[] GetPersonNameHasCertainPrefix(string prefixText, int count)"
So the only query condition I can get is the 'Person Name', when I type "John" in the textbox the list I get is the person name start with 'John' fromall of the company. but now I just want to get the person name start with 'John'in certain department.
I don't know how to get this.
Any help and suggestions are apperciated. Thank you all:)
"public string[] GetPersonNameHasCertainPrefix(string prefixText, int count)"
what is this ? is this method they are given (i.e u r database layer developer)
it is wrong .we must send department name to database query is must
or
send department name concadinating with name
like this
u selected software department
and u type john
send to this method as sofware+john as a one string .
change query to saprate that string
it is not suitable to u let inform briefly
Thank yousudhakargroup。
Maybe I didn't express myself clearly.
Anyway I have found the solution for this problem. The Ajax toolkit developer have left another overload method have a "contextkey" parameter, the type of it is STRING, so you can assign this parameter either in client or server side and pass it to the webservice.
Since it is a string, so you can pass almost everything, that's really great!^_^
No comments:
Post a Comment