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

  • SEARCH
  • Home
  • 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 4231146
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 21, 20262026-05-21T01:56:17+00:00 2026-05-21T01:56:17+00:00

I have a WCF Data Service running that is exposing an EDM. There are

  • 0

I have a WCF Data Service running that is exposing an EDM. There are several properties I needed on the client side, that the database doesn’t need to know about. After setting all that up I got to testing the SaveContext method and get this error on the server “Error processing request stream. The property name ‘CanDelete’ specified for type ‘DataModels.Customer’ is not valid.”

Is there a way to tell WCF Data Services on the client side to ignore this property? Or should I move to RIA Serivces? I’ve read that setting the property to internal will do this, but I need the property for binding and I have the client UI code in a different project (de-coupling my SL applications from my data service).

on the client I have:

 public partial class Customer
{
  private bool canDelete;

        /// <summary>
        /// Gets or sets a value indicating whether this instance can be deleted.
        /// </summary>
        /// <value>
        ///     <c>true</c> if this instance can delete; otherwise, <c>false</c>.
private bool canDelete;

/// <summary>
/// Gets or sets a value indicating whether this instance can be deleted.
/// </summary>
/// <value>
///     <c>true</c> if this instance can delete; otherwise, <c>false</c>.
/// </value>
public bool CanDelete
{
    get
    {
        return this.canDelete;
    }

    set
    {
        if (this.canDelete != value)
        {
            this.canDelete = value;
            this.OnPropertyChanged("CanDelete");
        }
    }
}
}
  • 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-21T01:56:17+00:00Added an answer on May 21, 2026 at 1:56 am

    I had the exact same problem and adapted some code below from
    extending partial designer classes

    It simply involves hooking the WritingEntity Event inside a partial class of the Context.

    I added my own attribute (IgnorePropertyAttribute) so I could attach it to other properties.

    Would of course be nice if the attribute wasnt inserted in the first place but this worked for me

    public sealed class IgnorePropertyAttribute : Attribute
    {
    }
    

    …

        partial void OnContextCreated()
        {
            this.WritingEntity += MyDataContext_WritingEntity;
        }
    
        private void MyDataContext_WritingEntity(object sender, System.Data.Services.Client.ReadingWritingEntityEventArgs e)
        {
            //
            foreach (XElement node in e.Data.Elements())
            {
                if (node != null && node.Name.LocalName == "content")
                {
                    foreach (XElement el in node.Elements())
                    {
                        if (el.Name.LocalName == "properties")
                        {
                            foreach (XElement prop in el.Elements())
                            {
                                if(e.Entity.GetType().GetProperty(prop.Name.LocalName).GetCustomAttributes(typeof(IgnorePropertyAttribute), true).Length > 0)
                                {
                                    prop.Remove();
                                }
                            }
                        }
                    }
                }
            }
        }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have client application that uses WCF service to insert some data to backend
I have developed a VB.NET WCF service that recives and sends back data. When
We have several Silverlight 4 apps running using WCF Data Services on our website.
I have a WCF service that I have to reference from a .net 2.0
I have a wcf application hosted in a windows service running a local windows
I have a WCF service running on the IIS with a ServiceHostFactory. It's running
How to access App_Data folder in WCF service? I have placed a xslt file
I have a WCF Web Service which is referenced from a class library. After
I have a WCF service hosted for internal clients - we have control of
I have some WCF methods that are used to transmit information from a server

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.