Actually none of the above worked.
Now instead of web form-code behind, I created a new asmx page & put it in the code behind Now, it shown some config issues: To solve it, I added:
<system.web>
<webServices>
<protocols>
<add name="HttpGet"/>
<add name="HttpPost"/>
</protocols>
</webServices>
............
in thw eb config file.
Now I am getting the output in the browser.
The only thing remaining now - is I want it as plain text (json).
But I get it as xml:
<ArrayOfString xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://tempuri.org/">
<string>abc</string>
<string>def</string>
</ArrayOfString>
I am looking to fix this also.