how to pass array object to web api method using angularJs
<p>I am creating a client-side script to send a dictionary object type to the web api method using <code>$http</code> as follows:</p>

<pre><code>    $scope.SearchPolicyDetails = function (data) {
    var searchPolicy = new Array();
    searchPolicy["InsuredName"] = data.InsuredName;
    searchPolicy["PostalCode"] = data.PostalCode;
    searchPolicy["LOB"] = data.LOB;
    searchPolicy["AgencyName"] = data.AgencyName;
    searchPolicy["Symbol"] = data.Symbol;
    searchPolicy["PolicyNum"] = data.PolicyNum;
    searchPolicy["MCO"] = data.MCO;
    searchPolicy["expireswithin"] = data.expireswithin;
    searchPolicy["SortFields"] = data.SortFields;
    searchPolicy["SortOrder"] = data.SortOrder;

    $http({
        url: "http://localhost:53054/api/GetPoliciesBySearch",
        dataType: 'json',

        data: searchPolicy,
        headers: {
            "Content-Type": "application/json"
        }
    }).success(function (response) {
        $scope.value = response;
    })

};
</code></pre>

<p>and I have this <code>WebAPI</code> method:</p>

<pre><code>    public List&lt;Dictionary&lt;string,string&gt;&gt; GetPoliciesBySearch(Dictionary&lt;string,string&gt; policySearch)
    {

        return SpecializedHandler.GetAllPolicies(policySearch).IterativeResource;
    }
</code></pre>

<p>But I am not receiving the object to the method.</p>

<p>I am seeing this error in the chrome console :</p>

<p><a href="https://i.stack.imgur.com/VrB0D.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/VrB0D.png" alt="enter image description here"></a></p>