CSLA .NET

Vibrant discussion about CSLA .NET and using the framework to build great business applications.

Strange behaviour of PTIdentity using statements

rated by 0 users
Answered (Not Verified) This post has 0 verified answers | 3 Replies | 1 Follower

Top 75 Contributor
106 Posts
griff posted on Wed, Apr 4 2012 5:53 AM

Hi

using latest csla 4.3.10.

I have used the PTIndentity and PTPrincipal sample code in my project - hooked up and working well.

However, if I amend these classes and save I get an error (any type of editing e.g adding a space):........

The using Csla.Serialization disappears from the code below.

using System;
using Csla;
using Csla.Security;
using Csla.Serialization;
;
 
namespace WACA.Business.Security
{
    [Serializable]
    public class PTIdentity : CslaIdentityBase<PTIdentity>

and I get the following error:
type or namespace name 'SerializableAttribute' could not be found (are you missing a using directive or an assembly reference?)	D:\Users\Richard\Development\VS2010\SLApps\WACA\WACA.Business\Security\PTIdentity.cs	7	6	WACA.Business.SL

However, if I don't save using the Save toolbar icon and instead close the code tab (VS2010) and accept the 'save changes' prompt  then it compiles okay and off we go all okay.
Anybody have any clues.
Richard





 

All Replies

Top 10 Contributor
9,282 Posts

Are you running any VS add-ins that might alter or refactor your code?

Rocky

Top 10 Contributor
1,815 Posts

Or you have a Silverlight project that references CSLA.dll for .net.

IIRC Silverlight does not have Serializable attribute so this is reimplemented in CSLA.dll for Silverlight.

Jonny Bekkum, Norway CslaContrib Coordinator

Top 75 Contributor
106 Posts
griff replied on Tue, Apr 10 2012 3:06 AM

Yes I do have a number of VS addins - some that refactor - presumably I need to switch these off and test.  (I have checked all my references and they seem okay) - thanks

Page 1 of 1 (4 items) | RSS

Copyright (c) 2006-2010 Marimer LLC. All rights reserved.
Email admin@lhotka.net for support.
Powered by Community Server (Non-Commercial Edition), by Telligent Systems