0

I've been searching far and wide for an answer, but every time I have come to a point where I'm hitting my head against a brick wall.

I need to have my data from WebApi served in a manner so that Ember-data can use them.

The following link seems to have the right answer: How can I add a custom root node when serializing an object with JSON.NET?

But this part isn't allowed in VisualBasic.Net

' GET api/<controller>
<JsonObject(Title:="users")> _
Public Function GetValues() As List(Of myclassname)

The following error is returned Attribute 'JsonObjectAttribute' cannot be applied to 'GetValues' because the attribute is not valid on this declaration type.

I suspect this to be something trivial... hoping, rather. :-)

Community
  • 1
  • 1
Bjerh
  • 71
  • 5

0 Answers0