Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6774081
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T15:44:40+00:00 2026-05-26T15:44:40+00:00

I would like to use WCF RIA Services to access data from my Silverlight

  • 0

I would like to use WCF RIA Services to access data from my Silverlight Application. However the data is not provided from a local data storage, but from another WCF Data Service (I’m accessing an external CRM system). I don’t want to access the external service directly because I have to mash up data from several data sources within my RIA service.

Is this possible an what would be the easiest way to achieve this? Some source code in C# would be appreciated.

EDIT:
The central problem is how to fill an entity from an external service in an easy way. There is a related question, but the answer does not solve my problem.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T15:44:41+00:00Added an answer on May 26, 2026 at 3:44 pm

    I think your confusion may be that the Visual Studio wizard for adding a RIA service assumes you will use the EntityFramework for your data. I don’t think you want to create an EF model out of the data from a second WCF service. Instead, create your RIA service to derive directly from DomainService and override the methods that you need. In each query method, simply query the remote service and return the result to the Silverlight client. In order for the RIA services magic code generation to work you will need to define a set of DTO objects in your app that wrap the results from the remote WCF service.

    Here is a quick sample. Note – I just made this up to illustrate what I mean. You will need to put in calls to the actual service you are using and build error handling, input checking, etc.

    namespace YourApp.Web 
    { 
        [EnableClientAccess] 
        public class WcfRelayDomainService : DomainService 
        { 
            public IQueryable<Restaurant> GetRestaurants() 
            { 
                // You should create a method that wraps your WCF call
                // and returns the result as IQueryable;
                IQueryable<MyDto> mydtos = RemoteWCF.QueryMethod().ToQueryable();
                return mydtos; 
            } 
            public void UpdateDTO(MyDto dto) 
            { 
                // For update or delete, wrap the calls to the remote
                // service in your RIA services like this.
                RemoteWCF.UpdateMethod(dto);
            }
        }
    }
    

    Hope that helps you out! See How to set up RIA services with Silverlight 4.0 and without EF for some more tips.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am using AdoNetAppender (SQL server) in my asp.net application and would like use
I would like to use VB9 but am not sure what syntax to use
I've been playing around lately with Entity Framework, WCF RIA Services, and Silverlight 4.
I would like to start a new instance of a wcf service host from
I would like to use WCF service hosted in IIS (5/6) with integrated windows
I use WCF netNamedPipeBinding and wsHttpBinding . I would like to know whether a
I would like to use a technology that is used for communication between services
I've used WCF RIA services with Entity Framework to build a simple application which
I would like to use the Authorization in WCF Hosted in Azure. At this
I would like to use Windows Forms with a WCF service and leverage the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.