I have just started using the SearchCompanyAsync with the SearchRequest set to Query = "Bay Horse", StartIndex = 0, ItemsPerPage = 100
Snippet
var request = new SearchRequest
{
Query = search,
StartIndex = 0,
ItemsPerPage = 100
};
var task = Task.Run<global::CompaniesHouse.CompaniesHouseClientResponse<global::CompaniesHouse.Response.Search.CompanySearch.CompanySearch>>(async () => await _companiesHouseClient.SearchCompanyAsync(request));
var companiesHouseClientResponse = task.Result;
var companies = companiesHouseClientResponse.Data;
if (companies == null)
{
result.Code = ErrorCodes.CompanyNotFound;
result.Message = "We could not find a company with that search term " + search;
return result;
}
When I make this call I get the following error message, :-
Error converting value "" to type 'CompaniesHouse.Response.CompanyType'. Path 'company_type', line 1, position 27814.
So I am assuming that the data that comes back from companies house is upsetting the Deserialisation code as its an empty or null company type.
Is there any chance you can look at why this is...
I have just started using the SearchCompanyAsync with the SearchRequest set to Query = "Bay Horse", StartIndex = 0, ItemsPerPage = 100
Snippet
When I make this call I get the following error message, :-
Error converting value "" to type 'CompaniesHouse.Response.CompanyType'. Path 'company_type', line 1, position 27814.
So I am assuming that the data that comes back from companies house is upsetting the Deserialisation code as its an empty or null company type.
Is there any chance you can look at why this is...
Regards Julian