DEVFORCE SILVERLIGHT APPLICATION: SILVERLIGHT PROJECT READ ME
-------------------------------------------------------------

To learn what to do next, please consult our "Getting Started" page, 
available from "Windows Start Menu | DevForce 2010 ..."

You'll also find more information online starting at http://www.ideablade.com/DevForceSilverlight/

------------------------------------------------------------------------------------------------

Hate to read? Think you can figure it out on your own? Here are some hints:

  1) Add an Entity Framework model to the Web Project ... if you haven't already done so 


  2) Edit "MainPage.xaml"

     a) Delete the "Hello, DevForce" TextBlock
     b) Replace with a DataGrid that fills the "Layout" Grid.
     c) In XAML, ensure the DataGrid "AutoGenerateColumns" equals "True"

   
  3) Edit the "MainPage.xaml.cs" code-behind using the following as a guide

	  public partial class MainPage : UserControl {
	    public MainPage() {
	      InitializeComponent();
	      Loaded += MainPage_Loaded;
	    }

	    private void MainPage_Loaded(object sender, RoutedEventArgs e) {

	       // Do not load your data at design time.
	       if (System.ComponentModel.DesignerProperties.GetIsInDesignMode(this)) return;

	       //Load your data here and assign the result to the CollectionViewSource.

	       // instantiate custom EntityManager (see your ".designer.cs")
	       var mgr = new NorthwindIBEntities(); 
	       
	       // "Get all Customers" query. 
	       // "Customers" is an example;
	       // Pick any of the generated queries in your mgr
	       var query = mgr.Customers; // you could add a "Where" clause, etc.

	       // Execute the query asynchronously (as you must in Silverlight)
	       var op = query.ExecuteAsync(); 

	       // Listen to the "operation" object's "Completed" event
	       // and pour query results into the data grid
	       op.Completed +=  
		  (s, args) => dataGrid1.ItemsSource = args.Results; 

	    }
	  }

  3) Compile and run ... you should see the browser window soon

  4) Give the web server and Entity Framework time to spin up

  5) Grid appears ... after a pause ... data appear

------------------------------------------------------------------------------------------------

Of course there are other, better ways to write an application; but few as quick!

Much more awaits you.  Feel free to delete this ReadMe file.  :-)