I'm using the very latest 3.6 2 release in VS2008.
In the cslacs dir there are snippets, templates and visual studio templates directories. How are these used?
In VS2008 I used Tools| Snippet Manager to import the snippets files. I can see them. Back in my code I can start to type say cslaprop. It comes up in intellisense. But when I press Tab or Enter it simply puts in the word cslaprop. It doesn't actually expand them out.
And the template directories, I'm not sure what to do with them at all :-(
Try to hit Ctrl+K+X. This should open up snippets drop
down, select your imported folder, and try to expand the same snippet.
This will verify that snippet is working correctly. Templates are sample
code files for each CSLA stereotype – such as root or child object.
They are intended to show you how to properly write code. You will need
to customize them of course to fit your needs.
Sergey Barskiy
Principal Consultant
office: 678.405.0687 |
mobile: 404.388.1899
Microsoft Worldwide Partner of the Year | Custom
Development Solutions, Technical Innovation
From: tkd
[mailto:cslanet@lhotka.net]
Sent: Saturday, October 25, 2008 1:00 AM
To: Sergey Barskiy
Subject: [CSLA .NET] Snippets and templates
I'm using the very latest 3.6 2 release in VS2008.
In the cslacs dir there are snippets, templates and visual studio templates
directories. How are these used?
In VS2008 I used Tools| Snippet Manager to import the snippets files. I can
see them. Back in my code I can start to type say cslaprop. It comes up in
intellisense. But when I press Tab or Enter it simply puts in the word
cslaprop. It doesn't actually expand them out.
And the template directories, I'm not sure what to do with them at all :-(
I haven't used the snippet wizard - maybe that's the issue?
I always just copy the snippet files into the "my documents"\VS2008\Code Snippets\C# (or VB) directory and they just show up.
But then again, you have them showing up in Intellisense, so they should be working for you.
All i needed to do was double click the vsi file found in
cslacs-3.6.0-081217\\cslacs\Visual Studio Templates\VSI\cs
cslacs.vsi
The Visual Studio Wizard asked me were to place the code snippets and the templates appeared as expected.
Great Job Nermin, well done!
Thank you for pointing this out, I’ll add it to the bug
list.
Rocky
From: jgamba
[mailto:cslanet@lhotka.net]
Sent: Thursday, January 08, 2009 7:08 AM
To: rocky@lhotka.net
Subject: Re: [CSLA .NET] Snippets and templates
Just one more simple concern, looking the code snippets for
properties, There are three labels that are identical.
Define a Csla Property
Define a Csla Property
Define a Csla Property
The issue is in 'DefineACslaConvertProperty.snippet' and
'DefineACslaSmartDateProperty.snippet', IMHO should alter these two code
snippets files, specifically the titles
DefineACslaConvertProperty.snippet
<Title>Define a Csla Convert Property</Title>
DefineACslaSmartDateProperty.snippet
<Title>Define a Csla SmartDate Property</Title>
Jorge
I was able to install the templates & snippets via the cslacs.vsi, but when trying to use several of the templates I receive the following error;
"Error: this template attempted to load an untrusted component CslaTemplateItemWizards, ....
It errors out when attempting to add DynamicRootList, EditableChildList, EditableRootList, ReadOnlyChildList, EditableRootParent, & ReadOnlyList.
I was able to successfully add CommandObject, DynamicRoot, EditableChild, EditableRoot, NameValueList, ReadOnlyChild, ReadOnlyRoot, and SwitchableObject.
Thanks in advance for any and all help,
Ralph
Thanks for your response. Yes I have installed 2008 sp1. Here is the complete error.
Error: this template attempted to load an untrusted component 'CslaItemTemplateWizards, Version=1.0.0.0, Culture=Neutral, PublicKeyToken=93be5fdc093e4c30'. For more information on this problem and how to enable this template, please see documentation on Customizing Project Templates.
Ralph
Copyright (c) Marimer LLC