BANGALORE, INDIA: Last month, we took a detailed look at how you can use the .NET RIA Services SDK for Silverlight to quickly create a Silverlight application that can not only talk to the database on the server to retrieve data, but also do more advanced things like sorting, filtering and paging with a minimal amount of code.
This time we'll continue on from where we left to add the ability to modify data by inserting, updating or deleting records using the same RIA Services. Let's pick up the project that we used last month and build upon it. Our project, named SLRIA, has a Domain Data Source called prodDataSource which talks to the NWDomainService in the SLRIA.Web application.
How to create Silverlight apps in Eclipse?
The domain service itself talks to a LINQ class that works with the Products, Suppliers and Categories tables in the NorthWind database. The Silverlight page also contains a DataGrid control called dgData that is bound to the domain data source and has a text filter as well as a data pager control attached to provide filtering and paging capabilities.
To allow the application to manipulate data you can actually go ahead and use the DataGrid control . The control allows you to change data within each record directly. However, this is usually a cumbersome method and what we'd like to do is to create a Master-Child form to allow richer data editing and addition. For this, we'll use DataForm control from the Silverlight Controls Toolkit.
Tips to view silverlight pages on Linux
This creates a new data entry control called dfDataForm with a header and editing disabled by default. It is also bound to the selected record in the data grid. On running the application, you will see a new data entry form at the bottom of the screen. You can click on any record in the data grid and the record details will show up in the form below correctly. This lets you perform a simple Master-Details view quite easily.
Integrate your work force and give a fight to your Competition.
Network with 2000 software professionals and create evangelists for your products.
About CIOL | Media Kit | Site Map | Contact Us | Help | Write to us | Jobs@CyberMedia | Privacy Policy
Copyright © CyberMedia India Online Ltd. All rights reserved. Usage of content from web site is subject to Terms and Conditions.