Code: Select all
Unhandled exception at line 0:
Script error.
More details can be found in the JavaScript Console output.
My block of code is:
Code: Select all
public string getParent(string creds)
{
string json1 = "{\"jsonrpc\":\"2.0\",\"method\":\"findLeads\",\"params\":{\"query\":{\"number\":" +
NSLeadBox.Text +
//7218 +
"},\"stubResponses\":false},\"id\":\"apeye\"}";
var webClient = new WebClient();
webClient.Headers[HttpRequestHeader.Accept] = "application/json";
webClient.Headers.Add("Authorization", "Basic " + creds);
string response = webClient.UploadString("https://app01.nutshell.com/api/v1/json/", json1);
return response;
}
The program runs as expected in the simulator. Any ideas on where I'm going wrong?