Development by Davis: “How open is too open?” plus 2 more |
- How open is too open?
- LightSwitch: reading threads from StackOverflow with OData
- Iceland's public administrations moving towards open source
Posted: 27 Mar 2012 03:00 AM PDT Last month, we posted a survey asking, "If you could open one of the following data sets tomorrow, which one would you open and why?" We got a great response–279 people voted and there were several comments. One commenter remarked that we should have made it multiple choice, avoiding an all-or-nothing outcome. And another pointed out that 'non-classified government data' could include private personal information--like tax records, for example. So, as always, how we ask these questions is incredibly important. |
LightSwitch: reading threads from StackOverflow with OData Posted: 26 Mar 2012 01:22 PM PDT As you might know, one of the most important new features in the next version of Visual Studio LightSwitch, currently in beta, is the support for OData. You can read some post from Beth Massi about this topic, today I'm just showing a different usage. OData is an open protocol based on WCF Data Services and allows managing data sets through services. If you visit the Ecosystem page of the OData portal, you can find a list of public services from 3rd party producers, including the well-known StackOverflow web site, which offers a very popular forum platform. Imagine you want to read your favorite threads from StackOverflow inside a LightSwitch application. After creating the project, the first thing you want to do is connecting to an external data source such as OData: In the next screen of the Wizard we specify the service URL and credentials if required. In this case no credentials are required and Anonymous auth is enough: In order to be sure that the connection works, click Test Connection and select the entity that will be used for the test: By clicking Test you will be able to check that everything works. The next step allows selecting entities you want to import into the application. We are talking about entities, this means that LightSwitch is able of representing OData information as the classic entity. So, working with OData is exactly like with any other data source, including business logic, validation, queries, and so on. Let's select posts, tags, and comments: When you click su Finish, LightSwitch will tell you that it needs to import the User entity as well, since this has a relationship with the Comment one. This demonstrates that LightSwitch perfectly knows how to handle this kinds of situations. Once imported entities and relationships, these will appear in the Table Designer the usual way: You can replace Date Time with Date to optimize visualization and you can change the summary property from Body to Title. Now imagine you only want to show posts talking about LightSwitch. You can simply create a Query the usual way; Right-click the Posts table in Solution Explorer, then Add Query. The new query is called LightSwitchPosts and we are going to set a couple of filters like in the following figure (tags are lower case): Now you can simply add a Search Screen pointing to the query: If you have changed the Summary Property to be Title, in the Properties window you can set this to be Show as Link. I am using here the Cosmopolitan shell which has been released recently. This is how the application will appear when running: As you can see we have retrieved the list of posts talking about LightSwitch in StackOverflow's forums. You can simply click the hyperlink to show the post details: OData in LightSwitch opens to infinite new development scenarios, making your applications even more powerful. Alessandro |
Iceland's public administrations moving towards open source Posted: 26 Mar 2012 09:00 AM PDT All public administrations in Iceland are increasing their use of free and open source software. The country's government recently launched a one year migration project for all of its public institutions. "The goal of the project is not to migrate public institutions to free and open source software in one single year but to lay a solid foundation for such a migration which institutions can base their migration plans on", reports Tryggvi Björgvinsson, the project leader. |
You are subscribed to email updates from Developers by Davis To stop receiving these emails, you may unsubscribe now. | Email delivery powered by Google |
Google Inc., 20 West Kinzie, Chicago IL USA 60610 |
No hay comentarios:
Publicar un comentario