warning message on Read only object

Mar 14, 2012 at 3:03 PM

Hi

can you advise on this please - readonly object - do I have to go into each data field and change to Managed - didnot think this was necessary for RO objects (unless say you are using authorisation) - using latest templates and version 03 mar 2012.

Validation: Business
* Warning:
Generation settings: 'Utility classes folder' will be ignored (separate namespaces in folders is set).

Passed.
Validation: DalInterface
Passed.
Validation: DalObject
Passed.

KeywordSearchInfo:
	File: D:\Users\Richard\Development\VS2010\SLApps\Abraca\Abraca.Business\ReadOnly\KeywordSearchInfo.Designer.cs
* Warning:
Property CatalogueID: must use Declaration Mode 'Managed' or 'ManagedWithTypeConversion' under Silverlight.
Property SchoolID: must use Declaration Mode 'Managed' or 'ManagedWithTypeConversion' under Silverlight.
Property ISBN13: must use Declaration Mode 'Managed' or 'ManagedWithTypeConversion' under Silverlight.
Property Title: must use Declaration Mode 'Managed' or 'ManagedWithTypeConversion' under Silverlight.
Property ImgCoverSmall: must use Declaration Mode 'Managed' or 'ManagedWithTypeConversion' under Silverlight.
Property ImgCoverMedium: must use Declaration Mode 'Managed' or 'ManagedWithTypeConversion' under Silverlight.
Property ImgCoverLarge: must use Declaration Mode 'Managed' or 'ManagedWithTypeConversion' under Silverlight.
Property NumberOfCopies: must use Declaration Mode 'Managed' or 'ManagedWithTypeConversion' under Silverlight.
Property NumberOnLoan: must use Declaration Mode 'Managed' or 'ManagedWithTypeConversion' under Silverlight.
Property Media: must use Declaration Mode 'Managed' or 'ManagedWithTypeConversion' under Silverlight.

	File: D:\Users\Richard\Development\VS2010\SLApps\Abraca\Abraca.Business\ReadOnly\KeywordSearchInfo.cs
KeywordSearchList:
	File: D:\Users\Richard\Development\VS2010\SLApps\Abraca\Abraca.Business\Collections\KeywordSearchList.Designer.cs
	File: D:\Users\Richard\Development\VS2010\SLApps\Abraca\Abraca.Business\Collections\KeywordSearchList.cs
	File: D:\Users\Richard\Development\VS2010\SLApps\Abraca\Abraca.Dal\Collections\IKeywordSearchListDal.Designer.cs
	File: D:\Users\Richard\Development\VS2010\SLApps\Abraca\Abraca.Dal\Collections\IKeywordSearchListDal.cs
	File: D:\Users\Richard\Development\VS2010\SLApps\Abraca\Abraca.DalAdo\Collections\KeywordSearchListDal.Designer.cs
	File: D:\Users\Richard\Development\VS2010\SLApps\Abraca\Abraca.DalAdo\Collections\KeywordSearchListDal.cs

Done
DataPortalHookArgs classe: already exists.
IDalManager classe: already exists.
DalFactory classe: already exists.
DataNotFoundException classe: already exists.
DalManager classe: already exists.

Object warnings: 1 object.

Classes: 4 generated. 0 failed.
Stored Procs: 0 generated. 0 failed.
Mar 15, 2012 at 8:07 PM

Have sorted - I would have thought that as the project was marked for silverlight that the readonly object would automatically generate Managed fields

Coordinator
Mar 15, 2012 at 9:40 PM
Edited Mar 15, 2012 at 9:40 PM
zen8019 wrote:

Have sorted - I would have thought that as the project was marked for silverlight that the readonly object would automatically generate Managed fields


Hi Richard,

CslaGenFork generate managed fields according to the setting under

Project Properties

Creation tab

General Defaults tab

ReadOnly Objects group

Property Mode for columns combo box

I think you are right; when (plain) Silverlight is selected, it should force the declaration mode to Managed and also change the above referred setting to Managed.

Suppose your project wasn't intended to generate Silverlight. You create your RO objects with setting AutoProperty. Later on, you decide to generate Silverlight code. It's a PITA to go to every RO object and change the declaration mode of every property to Managed. Unless... you decide to handle it by yourself under #if SILVERLIGHT conditional compiler directives in order to retain AutoProperty on non-Silverlight assemblies. So, when you set the Silverlight setting, CslaGenFork should ask you wheter you want to change the declaration mode to Managed and UnmanagedWithTypeConversion. If you agree, CslaGenFork should do that for you.

Coordinator
Mar 15, 2012 at 9:42 PM
This discussion has been copied to a work item. Click here to go to the work item and continue the discussion.
Mar 15, 2012 at 11:08 PM

Thanks for the reply

From: tiago [email removed]
Sent: 15 March 2012 21:40
To: richard@rgsoft.co.uk
Subject: Re: warning message on Read only object [cslagenfork:348574]

From: tiago

zen8019 wrote:

Have sorted - I would have thought that as the project was marked for silverlight that the readonly object would automatically generate Managed fields


Hi Richard,

CslaGenFork generate managed fields according to the setting under

Project Properties

Creation tab

General Defaults tab

ReadOnly Objects group

Property Mode for columns combo box

I think you are right; when (plain) Silverlight is selected, it should force the generation of Managed properties and also change the above referred setting to Managed.

Suppose your project wasn't intended to generate Silverlight. You create your RO objects with setting AutoProperty. Later on, you decide to generate Silverlight code. It's a PITA to go to every RO object and change the declaration mode of every property to Managed. Unless... you decide to handle it by yourself under #if SILVERLIGHT conditional compiler directives in order to retain AutoProperty on non-Silverlight assemblies. So, when you set the Silverlight setting, CslaGenFork should ask you wheter you want to change the declaration mode to Managed and UnmanagedWithTypeConversion. If you agree, CslaGenFork should do that for you.

No virus found in this message.
Checked by AVG - www.avg.com
Version: 2012.0.1913 / Virus Database: 2114/4872 - Release Date: 03/15/12