Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to cast object of type 'System.Object' to type 'Newtonsoft.Json.Linq.JObject'. #5

Open
brownrw8 opened this issue Oct 7, 2021 · 0 comments

Comments

@brownrw8
Copy link

brownrw8 commented Oct 7, 2021

At line 458 of TestPowerCast/Form1.cs, the cast to JObject is failing.
message = String.Format("The request was not accepted by the PowerCast Hub. Error code: {0} Reason: {1}", response.StatusCode, (**(JObject)responseObject**)["message"]);

Exception thrown is:

An exception of type 'System.InvalidCastException' occurred but was not handled in user code
Unable to cast object of type 'System.Object' to type 'Newtonsoft.Json.Linq.JObject'.

Exception

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant