Introduction
Castle Visual Studio Integration (CVSI) provides Microsoft Visual Studio 2005/2008 integration for the Castle Project. Currently it only contains a colorizer and IntelliSense for the NVelocity language.
Current Version: 0.3.2 (30 Sep 2008, r625)
Download: CVSI-0.3.2.msi
(1.26 MB)
Old Releases
- 0.3.1: CVSI-0.3.1.msi
(1.26 MB, 15 Aug 2008, r616) - 0.3.0: CVSI-0.3.0.msi
(1.26 MB, 29 Jun 2008, r576) - 0.2.1: CVSI-0.2.1.zip
(178 KB, 29 Oct 2007, r339) - 0.2.0: CVSI-0.2.0-Alpha.zip
(177 KB, 09 Oct 2007, r317) - 0.1.3: CVSI-0.1.3-Preview1Update.zip
(23 KB, 27 Jul 2007, r257) - 0.1.2: CVSI-0.1.2-Preview1Update.zip
(22 KB, 13 Jul 2007, r253) - 0.1.1: CVSI-0.1.1-Preview1Update.zip
(22 KB, 12 Jul 2007, r252) - 0.1.0: CVSI-0.1-Preview1.msi
(636 KB, 01 Jul 2007, r245)
See https://svn.castleproject.org/svn/castlecontrib/CVSI/trunk/doc/Changes.txt
for full details of the changes.
Source
| New Project Wizard If you are looking for the New Project wizard you will need the official Visual Studio integration. See http://www.castleproject.org/castle/vsintegration.html |
Screenshot

Thanks for you work. I think it is really important to have intellisense facilities, specially to make life easier to newcomers like me. Great job. Thanks again and keep this contribution alive, please!! ![]()
Hi,
We're starting out with the Castle stack. We've a end-to-end prototype ready. I've also got the contrib strongly-typed View code integrated and we've got jquery integrated. Good times.
I was also bouyed that there was a new 2008-compatible release of the VS integration. Installed the above, no change. New Project -> has no Castle Projects available. Also no view / intellisense changes.
Am I missing something ? Tried reboot - no effect.
cheers, ian
If you are after the New Project wizard you will need the official Visual Studio integration, which looks like this:
http://www.castleproject.org/castle/vsintegration.html![]()
If you don't see your .vm files colourised, have you checked to make sure you don't have .vm already associated with the XML or HTML editor?
CVSI is definitely a huge help - thanks for doing such a great job.
I've run across one small issue using version 0.3.1 in VS2005 & 2008 that I thought I'd pass along. Colorization and intellisense stops when adding attributes to existing $Form code, specifically when I type the percent siqn that precedes the attribute list. Oddly, I can type everying but %, then insert the % character last, and it works. I'm also using ReSharper 4.1.
i still don't understand i have installed the castle and the CVSI, but it doesn't show up in the wizard :s
what could be?
i installed vs2005 and installed the CVSI, and nothing happens too
As I mentioned a few comments up CVSI doesn't contain a new project wizard, you'll need the official Visual Studio integration. I have added an info box to this page so others are more easily able to find the wizard. If you have any problems with the new project wizard please direct your questions at the users mailing list, where there are many more people that can help you.
Jono
The Velocity/HTML-Parser has an error. It is not able to handle the following simple example:
<p>Some text</p> <!-- A comment -->
At the end of the comment it signals an error. The error output is as follows:
The parser has been pre-emptively terminated because it appears as if the parser is stuck. [In ParseXmlRestElement()]
Expected 'XmlTagStart' but was 'XmlComment'
Expected 'XmlForwardSlash' but was 'XmlComment'
Expected '>'
Obviously it doesn't expect a comment there but a tag.
Thanks for reporting this defect. Would you mind logging it in donjon at http://support.castleproject.org/projects/CONTRIB
with the CVSI component.
Jono
I have installed above msi installer still i am got getting intellisense in vm file. I am using VS 2008 trail version. I havent installed any thing for nVelocity just referring ddl which is provided in http://builds.castleproject.org/
(latest successful version). Do i need to install anything for nVelocity? and also how get the intellisense in vm file?
Are you getting colourisation in the NVelocity files? If so, can you try intellisense for directives to see if you get a list; just type # and you should get a list with if, foreach, etc.
Thank for you reply. Im getting colorisation. If i type #, no listing is showing.
I haven't seen this issue before. Does your VS error window show any errors? Can you try typing # in a blank file.
2 more comments by: John Simons, Jonathon Rossi
I tried in blank file its not showing and also i have seen HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\9.0\Default Editors\ - it has only default registry. Can you please tel me steps which i need to follow to work in castle monorail with Intellisense using VS 2008.I dont have VS 2005 in my system. i will start installation from beginning. Please let me know what to be done?
CVSI works in VS2005 and VS2008 (the screenshot above is just really old). I am really out of ideas, could you debug CVSI and take a look to see if VS calls the ParseSource method in NVelocityLanguage.
Thanks for you support, Today i again installed it. now its working fine. if i type # and $ intellisense is showing up
. when i typed following statement $Form.FormTag("%
There is no intellisense for dictionaries because there is no easy way to know what you are allowed to enter in the dictionary.
2 more comments by: Jonathon Rossi, Sandeep Kumar
Thanks, it's great to have syntax hilighting for VM. One feature to ask for though. We have a number of .vm files that generate javascript only, no html (the idea being that they're included elsewhere by a <script src="foo">).
CVSI gets freaked out and throws parser errors on these files because it's expecting HTML tags. Any way I can tell it to just ignore those files?
Ideally I'd like to see Javascript syntax hilighting built in to CVSI.
I tried:
//<script>
contents of my file
//</script>
in the hopes of just not hilighting these files, but it didn't work for some reason. Any other suggestions?
Hey Mike. Sorry for taking so long to respond.
CVSI assumes the file is XML, currently there is no way to tell it otherwise. It would probably be a good idea for it to work out whether or not it should parse the file as XML because I know I have some .vm files that generate C# and it does the same thing.
Feel free to log an enhancement in the castle issue tracker under the contrib project. I think there is already one for JavaScript highlighting. Also free feel to provide a patch to either ![]()
There's anyway to change font color for VM files in editor?
I'm using a black background and the plain text are black in a black background, in other words the plain text isn't show in editor.
Take a look below:

John, please see this thread on the Castle development mailing list. It may fix the problem for you.
http://groups.google.com/group/castle-project-devel/browse_thread/thread/32151ad11e14f465?hl=en![]()

how to use it by vs2005.
after I install it ,but in my project I edit vm file that is still like before.how to do it?