I am new to Telerik and I am currently trying to implement a Restful Web Service App that will accept Http injects and either display or process data. I have performed the following steps and I am having trouble:
- I have created a new Class Library project in visual studio.
- I then added a "Telerik OpenAccess Domain Model" to that project and successfully linked it to my database.
- I then Added a web project to my solution.
- I then used the Data Services Wizard (DWS) to create a REST Collections for the app, this was successful.
- From this a number of files were added to the project icluding ICollectionService.cs, DataManager.cs, Users.svc etc.
From here I then wanted to view the data in my database in xml or json. I setup some routing so that i could more easily access the service, as shown below:
Global : HttpApplication
sender, EventArgs e)
// Edit the base address of Users by replacing the "Users" string below
Once I then run the application and went to the routing address which should have pointed me to the Service I got an error saying is not compatible with asp.net, so I added the below code to the Users.svc.cs to fix it:
[AspNetCompatibilityRequirements(RequirementsMode = AspNetCompatibilityRequirementsMode.Allowed)]
Now When I run the application and go to say the following address "http://localhost:14644/Users/
", I get the results as shown below where as I would like it to show me the data in an XML/Json format.
Can anyone please help with this? If you need more info please let me know.