Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C# WCF LightSwitch
Hello All,
i am making a visual studio light switch project.And i am adding a WCF RIA service to this project and I am using some references as bellow...
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.ServiceModel.DomainServices.Hosting;
using System.ServiceModel.DomainServices.Server;
using ApplicationData.Implementation;
using System.Data.EntityClient;
using System.Web.Configuration;
 
But I am facing a problem the namespace ApplicationData.Implementation is showing assembly error.Can someone help me to tell which assembly reference needs to be added for this namespace....
 
Thanks And Regards
Shivam Kumar
Software Engineer
Posted 23-Mar-13 3:07am
Comments
Sandeep Mewara at 23-Mar-13 14:47pm
   
From where did you got this namespace: using ApplicationData.Implementation;?

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

Dear Shivam,
 
I have faced the same problem while I was working on a tutorial for WCF RIA Services for a LightSwitch application. It is not an assembly that you need to reference. ApplicationData is a class that LightSwitch automatically creates, in order to communicate with the Intrinsic database of LightSwitch (LightSwitch creates a LocalDB development database in the location \Bin\Data\Temp\ApplicationDatabase.mdf).
So you need to add this ApplicationData class to your WCF RIA Service project to communicate with the LightSwitch database.
To do that you need to Right-click on your WCF RIA Service project and select Add then Existing Item.
Navigate to ...'YourLightSwitchProject'\Server\GeneratedArtifacts and click on ApplicationData.cs and Add As Link.
It is recommended to use "Add As Link" so that whenever LightSwitch updates this class, WCF RIA Service is also updated.
As soon as you add ApplicationData.cs class as a link to your WCF RIA Service the problem you face with using ApplicationData.Implementation will be solved.
 
Best Regards,
 
Vassilis Tsolekas, MSc
Senior Software Engineer
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 587
1 Sergey Alexandrovich Kryukov 479
2 Maciej Los 305
3 Mathew Soji 195
4 Richard MacCutchan 145
0 OriginalGriff 7,356
1 Sergey Alexandrovich Kryukov 6,712
2 DamithSL 5,461
3 Manas Bhardwaj 4,916
4 Maciej Los 4,475


Advertise | Privacy | Mobile
Web02 | 2.8.1411023.1 | Last Updated 17 Jun 2014
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100