Tag | Resharper Posts

This week I was handed a "simple" requirement - have a search screen execute its search when the user pressed the Enter key instead of having to move hands from keyboard to mouse and click Search. That is a reasonable request that has been met for years both in Windows and Web apps. I did a quick scan for code to pilfer and found Patrick Cauldwell's Blog posting "A 'Default Button' In Silverlight". This posting was a great start and I'm glad that the basic work had been done for me, but I ran into ...
Version 5.1.3 of Resharper has been released by Jetbrains. Download is at http://www.jetbrains.com/re... The release notes are at http://blogs.jetbrains.com/... Whilst 5.1.3 addresses just a specific issue, if you are programming in C# or VB.NET and if you have never tried Resharper before, you should try it. When I first saw ReSharper in use, within a few minutes I knew that it was worthwhile buying my own copy. Since then I have used ...
Developers that use unit testing are familiar with Resharper and his plugin for Unit Testing. For those that like me, don't have a great pc hardware (Pentium 4, 3ghz, 1GB ram) the Resharper can be really slow, and affect the performance of pc. That's why i use TestDriven.NET TestDriven.NET is a freeware license tool (there are others licenses for this product) that gives us the possibility to run unit tests with this plugin, that's integrated with Visual Studio. You can check some screenshots here: ...
Style Cop 4.4.0 is now out. This is a free download from http://stylecop.codeplex.com/ (please note the new location). This version is for VS2010. If you are usign an older version of Visual Studio you be prepared to keep to an older release like 4.3.0. The more I use StyleCop the more I like it. Code that is style cop compliant is much easier to pick up. It helps if you have GhostDoc (free) and Resharper (from jetBrains.Com) ...
Part 1 | Part 2 | Part 3 | Part 4 I wanted to create a series of blog post that gets right to the point and is aimed specifically at Silverlight Developers. The most important things I want this series to answer is : What is it? Why do I care? How do I do it? I hope that you enjoy this series. Let’s get started: Tip/Trick #16) What is it? Find out version information about Silverlight and which WebKit it is using by going to http://issilverlightinstall... Why do I care? I’ve had ...
This post is about VS 2010, go here for the VS/TFS 11 extensions. UPDATED Apr 9th 2012: VersionInfo, NuGet, Code Contracts UPDATED Oct 7th 2012: New Visual Studio GDR UPDATED Aug 31th 2012: New versions updated of ReSharper, NDepend, Web Essentials, Community Build Manager, Code Contracts (March 2012), NuGet, ILSpy, DotPeek, Just Decompile, tangible T4 editor, LinqPad. Added the VersionInfo tool, so you know you have the latest update of VS 2010 UPDATED April 20th 2012: New version of NuGet manager. ...
My coworker and I were working a little later than our teammates this evening, and while reflecting on this week's work, we discovered this gem thanks to the venerable ReSharper and its code analysis (it detected an unclosed tag): <%@ Control Language="C#" Inherits="System.Web.Mvc.Vi... %> <div class="product-table grid"> <% var i = 0; var j = 0; foreach (var item in Model) { %> <% if (i % 4 == 0) { %> <% if (j != 0) { %></div><% ...
Motivation Schon im Whitepaper „Auszeichnung von COM-Kategorien an .NET-Klassen mittels Attributen und deren Verwendung für Setup-Builds“ [1] habe ich deutlich gemacht warum das Verwenden von COM-Registrierungsfunktionen ein suboptimales Programmierpattern ist. Knackpunkt sind die Verstöße gegen SOC (separation of concerns) [2] und SRP (single responsibility principle) [3]. Für Prototyping oder kleine Demoprojekte möchte man vielleicht aber bewusst diese Verstöße in Kauf nehmen. Nichtsdestotrotz ...
IDE Must have Visual Studio 2008 Visual Studio 2010 Nice to have Sharp Develop Eclipse Editor Must have Editor with high functionality and high usability (like WScite, UltraEdit, PSPad, ..) Nice to have Microsoft XML Notepad 2007 Notepad++ Windows Live Writer WScite Visual Studio Add-Ins Must have AnkhSvn GhostDoc PowerCommands PowerToys for Visual Studio ReSharper VsCommands Nice to have CopySourceAsHtml Clone Detective for Visual Studio CR_Documentor, Documentor Agent Johnson (R# Plugin) Agent ...
Technorati Tags: .NET If you use Resharper, you've probably seen it recommend that you make private methods static if they don't use any instance data or methods. FxCop also has a rule (CA1822) about this: "Methods which do not access instance data or call instance methods can be marked as static. After doing so, the compiler will emit non-virtual call sites to these members which will prevent a check at runtime for each call that insures the current object pointer is non-null. This can result in ...
The Back Story: As a Microsoft MVP awardee, one of the many benefits is free software, books, and various products. Some of the producers/manufacturers ask for reviews in exchange, others just ask for a brief mention (nothing is ever really free). But considering that some of the products are essential to my everyday computing, I never mind mentioning their names and evangelizing their products. One of these tools just happened to save me a countless number of hours. With the release of Microsoft’s ...
This morning I finished removing all VS2008 related frameworks and installed items related to VS2010 based on posts around the community. Here’s what I started with on my dev laptop, the config for my laptop: HP Pavilion dv6 Win7 64-bit 4Gb RAM Installed Developer Tools and Frameworks: Sync 2.0 SDK Visual Studio 2010 Pex Power Tools Enterprise Library 5.0 SQL Server 2008 Developer Edition Visual Studio 2008 Ultimate Expression Blend 4 RC Team Foundation Server 2010 Team Foundation Server 2010 SDK ...
Carl and Richard are loading up the DotNetMobile (a 30 foot RV) and driving to our town again to show off their favorite bits of Visual Studio 2010 and .NET 4.0! Richard talks about Web load testing and Carl talks about Silverlight 4.0 and multimedia. And to make the night even more fun, they are going to bring a mystery rock star from the Visual Studio world to the event and interview them for a special .NET Rocks Road Trip show series. Along the way we’ll be giving away some great prizes, showing ...
I think back to the days of the first versions of Visual Studio (when it was called Visual Studio .NET, remember?) and I think about how far Microsoft has come with this IDE. It really is the best IDE on the market. There is so much to this IDE it is amazing. It now can really handle managing your complete software application development lifecycle. For me, it is (besides Windows 7) the best and most successful product Microsoft has developed. You can obviously get this now and it is available on ...
The refactoring I’m talking about is recommended by resharper when it sees a lambda that consists entirely of a method call that is passed the object that is the parameter to the lambda. Here is an example: public class IWishIWasAScriptingLanguage { public void SoIWouldntNeedAllThisJunk() { (new List<int> {1, 2, 3, 4}).Select(n => IsEven(n)); } private bool IsEven(int number) { return number%2 == 0; } } When resharper gets to n => IsEven(n) it underlines the lambda with a green squiggly ...
The catch? Attend the Ozarks .Net User Group meeting on April 1st. Here’s a list of the other prizes for the event GRAND PRIZE 1 - iPad (Wi-Fi 16GB) THIRD PARTY COMPONENTS 6 - Telerik Premium Collection 5 - Infragistics NetAdvantage for .NET 1 - Nevron Chart for .NET Lite DevExpress Xceed PRODUCTIVITY 2 - CodeRush with Refactor! Pro 2 - ReSharper CodeSmith GAMES 3 - Halo3 ODST (XBox 360) 3 - Forza Motorsport (Xbox 360) OTHER SOFTWARE 3 - Windows 7 Ultimate 2 - Microsoft Office Standard 2007 HARDWARE ...
For those in the Ann Arbor, Michigan area, you might be familiar with the “Come Jam With Us” project. Every week, we get together for an hour and code on a particular topic. It is usually led by one or two people and the rest of the group codes along in order to learn about the topic at hand. It is a really great forum for learning new concepts and technologies. This week, on Tuesday, March 2nd, I will be hosting an MVVM jam session at 5:30 (directions). I will be taking you through the process of ...
Original post: Weird resharper issue with action lists that don't work. - Stack Overflow Export your current settings in Visual Studio. Tools > Import & Export Settings > Export settings Save your settings… Use the VS CMD prompt and enter: devenv /resetsettings Import your saved settings in Visual Studio. Tools > Import & Export Settings > Import settings If all is well, you’re good to go… Tags: Note to Self,Resharper,Visual Studio,Action Lists ...
In this Issue: Joel Neubeck, Tim Heuer, Gill Cleeren, Cameron Albert, Damon Serji, Matthew Casperson, Corey Miller, Pete Brown, Aashish, David Poll, and Fredrik Normén. Shoutouts: Brad Abrams reported an interview: Bytes by MSDN: Brad Abrams Interview with Billy Hollis: Silverlight 4, RIA Services and VS2010 Nikhil Kothari has a set of links for RIA Services: RIA Services Link Listing #1 From SilverlightCream.com: Capturing the Webcam in Silverlight 4 Joel Neubeck has a post up at SilverlightShow ...
Installing StyleCop for ReSharper under an administrative account does not activate this ReSharper plugin under my developer account. A system analysis show, that this plugin is installed under %userprofile%\Local Settings\Application Data\JetBrains\ReSharper\v4... StyleCop for ReSharper This gives the hint, that the msi must be started for each individual user separately – maybe the is the possibility to move the stuff to all users or that there is also an administrative installation ...
Today a colleague ask me to help. On his system all ReSharper menus are grayed out. Also the Visual Studio Add-In Manager does not show this add-in. He tried: a new installation: without success, running with administrative privilegeg: without success, looking in event- and application-logs: no entries. After searching a little bit with old buddy google we found this message: Wild World of Visual Studio -- Mysterious Component We downloaded and installed the latest Microsoft Core XML Services (MSXML) ...
This is how we do code review in my actual team: Rules: No check-in without a code review (unless we paired on the task) Let the others know half an hour earlier that you might need a code review (so they can put up with the thought :D ) Try to change the reviewer as often as possible, so you should not care that the person who reviews you is in blue or red team Try to code review small amount of code, as it is easier (and this relates to another rule that we try to follow, no to leave code unchecked ...
JetBrains is releasing nightly builds of ReSharper since Monday. R# looks very promising so I installed it. But my favorite tool just got easier to update. Scott Cowan just published a tool to upgrade ReSharper 5.0 EAP automatically. Just like the previous version of the ReSharper Updater, it just works. Thanks Scott ...
In our team we have developers with Visual Studio 2005 and 2008. Often we have projects which must be coded by a mixed team. Visual Studio 2005 and 2008 compatibility for project-files Normally this is no problem because adding projects in Visual Studio 2005 and manually introducing the ToolsVersion="2.0" attribut in the new csproj-file allows an coexisting working when using two sln-files for Visual Studio 2005 and 2008. We name the sln-files normaly <solution>.2005.sln and <solution>.2008.sln. ...
This morning I had the chance to speak with Ben Scheirman. We chatted for roughly an hour or so discussing how he entered into the web development industry, going on the road to teach ASP.NET MVC in its early days, his book ASP.NET MVC in Action, and his thoughts on the use of the MVC framework. We discussed some patterns and tools for testing, tools for development in general such as ReSharper, and the use of the Spark View Engine. Watch for this podcast to be posted within the next couple of days. ...
Just stumbled across some pretty cool functionality with Jet Brains ReSharper 4.0 (you may already be familiar with it, but who cares, it’s still cool!) Basically, ReSharper has a Surround With tool that allows you to surround a selection of code with… more code. It comes with a bunch of predefined templates, like if..else, using, while, try..catch blocks, but you can edit existing templates and also create and organize your own custom templates. To get to the Templates Explorer, select ReSharper ...
I’m a big fan of Resharper. Its loaded with refactoring and best practice guidance that makes me a better developer. I’ve also started working with .NET RIA services. The verdict is still out on RIA services, but I think I like them. Unfortunately RIA has an interesting approach to code sharing between the web and Silverlight project that's incompatible with Resharper. It used generated code that is technically excluded from the project. As a result, any code in my Silverlight project that references ...
I've noticed in my LINQ code Resharper Warning "'Access to modified closure'". The search pointed that there is very confusing potential error. If for/foreach loop variable is used only in Linq methods (more general, only as a parameter for delegates) , only the last value of the variable will be used for all calls. It always required to create local variable inside loop and use the local variable instead of loop variable. More about the issue: Linq: Beware of the 'Access to modified closure' demon ...
I’m currently using context/specification style tests. While I think frameworks like J.P.Boodhoo’s are beautiful, I prefer something that works with ReSharper, TD.NET and CI without extra hurdles. I also want something my team, with limited exposure to *Unit frameworks, can easily pick up. I’d prefer not to have the ceremony and misleading terminology of “Test” attributes, but its a trade-off I’m willing to make to more easily to integrate with team members and third party tools. I put my testing ...
Check the add-ins you installed before Visual Studio 2010 if you enabled VS 2010 integration in them. Particularly TestDriven.NET is the problem. Go to “Add Remove Programs” / “Programs and Features”, find Test Driven.NET, click “Change”, and then modify it to remove VS2010 integration from it. Also, if you are using AnkhSVN, make sure to download a new latest daily update build and use that, otherwise, you’ll get an exception when starting VS 2010. I’ll be writing more about VSTS 2010 and .NET 4.0 ...
Today I have been using a ReSharper keyboard shortcut to rearrange chunks of code. I needed to move a method above another method in a class. With the cursor at the beginning of the line inside the chunk I want to move, I hit: Ctrl+Shift+Alt+UpArrow and it moves the entire method up one section (above the method before it). So.. given: public string SomeMethod() { Here.Is.SomeCode.ToBe(Super... } public string MyMethod() { Here.Is.SomeCode(that).Save... } I put my cursor at the line ...
New version of ReSharper has released! As announced, the new version features major improvements in performance and memory usage. In addition to focusing on performance enhancements, JetBrains also added a number of intelligence features and improvements. Also, you can see small flash movie about new features in ReShareper 4.5. ReSharper it is a great tool and it is cool that new version is released. You can download it here: http://www.jetbrains.com/re... ...
Much like my previous post about what I use for testing in Silverlight, I was recently asked on Twitter for my ReSharper NUnit templates. I am posting them here if anyone finds them useful. Basically, I write a LOT of tests every day. These templates allow me to write tests faster. New Test File Template This file template adds a new “Test” target when you say tell Visual Studio to create a new file from template. It populates your file with the correct namespaces and decorations to get you started. ...

Up until now, I installed new releases of the ReSharper 4.5 EAP when I thought about it. Sleepoverrated just posted a tool to automatically check for new release. When a new release has been found, it proposes to install it automatically.

Thanks to JP for the link.

I wanted to make sure and draw attention to the effort that Brandon King in Harrison, Arkansas has given towards promoting this event. There are some major giveaways, and we will be arranging a carpool from Springdale to drive the 1:30 to give a good showing from the NWA DNUG crew. Details: Who: CLAUDIO LASSALA What: Details at http://odnug.org When: April 2nd 5:30 PM – 8:30 PM Where: North Arkansas College (Center Campus - Durand Center - Old Regions Bank Building), Harrison, AR Grand Prize Inspiron ...
My trial ran out a few days ago. And I haven't posted about R# for almost a month. I have to a few more things to share, and perhaps I can save everyone some time. The R# team has done quite a few small things to raise the tool a step above my expectations. There are a lot of things that may seem small, but really turn out to be significant improvements to the way I manage my code. Simple things, like, locating new code (via refactoring) with similar declarations (fields with fields, properties with ...
Last Thursday evening (Feb 5th), SSE sponsored a local developer bootcamp covering VS.NET 2008. We had a great turnout and a lot of great discussion and questions. If you are in the St. Louis area and interested in being invited to these bootcamps please drop me a line at kvgros@sseinc.com. First, I wanted to thank everyone on my various teams who contributed ideas for the talk. While I did do a lot of research for the event, many developers contributed some good ideas that found there way into the ...
I've been using ReSharper now for about one and a half weeks. Now that I am writing some new code, I have more to share. The most helpful and time saving feature that I have encountered so far is code generation. In one case, I had added a couple of new properties to one of my entity objects. In actuality, I add the code in my test first. R# quickly recognized that the property didn't exist and gave me the option to create a field or property. I chose the property option and presto, R# found my class ...
Recently I blogged that the Resharper install corrupted TestDriven.Net. I followed up to say that certainly wasn't the case. In fact, there was nothing wrong with TestDriven.Net. The problem was between the keyboard and chair. I kept getting an error about not being able to load one of my base test classes. At compile time everything was fine. I would get the error only when trying to run the test in TestDriven.Net. R# could run the tests with no problem. This led me to believe it was a problem with ...
I've discovered what was causing problems with TestDriven.Net and it isn't ReSharper. I had recently refactored my test fixtures and now I have a few that make use of generics BaseTest<T>. I had run into a problem with TD.Net before regarding generics and had to rearrange my classes (I had two classes in one file) to get it to work. I don't remember the details and I am still having problems getting it to work now. Regardless, R# is off the hook. And as an added bonus, R# doesn't appear to ...
So day two brought more items of interest. Unit Testing still problematic Apparently, ReSharper installs with version 2.2.8 of NUnit. I am using 2.4.8 which includes syntax helpers. A bunch of my tests were failing with multiple TypeLoadExceptions. To resolve the issue, I ran the tests in debug mode and took a look at where the nunit.framework library was being loaded from. I found that it was being loaded from C:\Program Files\JetBrains\ReSharper\v... Once I determined that I was dealing with ...
I finally installed ReSharper yesterday to try it out. I've been dragging my heals because I didn't want to have to learn a bunch of new commands and pay for that right (I'm cheap, I know). Here are a few things I noticed immediately. Keep in mind that these are first impressions, and they are sure to change over the next couple of weeks. [Update] I turns out that ReSharper is not the culprit here. See this post for more details. TestDriven.Net broken after ReSharper install. Any time I attempt to ...
I started this blog back in September with a particular purpose in mind. Every yahoo and his brother has a blog these days, and by far the majority of them are absolute trash, but every so often there's a gem. As developers, we seem to mostly agree on which ones are the gems. Non-developers most likely have different lists, depending on their focus. There's a long list of blogs I love to read, and couldn't possibly hope to be counted among them, but one day I realized something. There's a lot of ...
In this issue: Alex Golesh, Silverlight SDK, John Stockton, Page Brooks(2), Mike Snow(2), Terence Tsang(2), Adam Kinney, Shawn Wildermuth, Jesse Liberty, and Jonathan van de Veen. Shoutouts: Adam Kinney has some good comments about a much-viewed Surface video: Extending the Surface experience in the BMW app. Jesse Liberty waxes poetical about divElements, and it looks like with good reason :) SandDock for Silverlight – Commercial floating windows Corey Schuman is going to be on GeekSpeak on the 10th: ...
It's been a three or four days now since I returned from PDC. After seeing all the other bloggers give detailed descriptions of the sessions and parties I didn't feel too obligated to add too much of my own spin on topics heavily covered by others. Instead, I thought I'd wait till the recordings were available and share links to the highlights I was witness too. As to my thoughts on having the recordings available so quickly after the conference and of such a high quality, I can only say I am very ...
I find it important to have a common development environment in our team. This allows us to easily switch seats during the sprints. ReSharper has a lot of customizable features, and we just figured out how to share these. Code conventions If your team agrees to name all local variables with a prefix of "local" (which I wouldn't advise, but hey, the team decides), you can set that in Re#. This will not enforce anything, it will just provide you with default choices. The result will look like this: ...
Ok, now I'm certain the creationists and intelligent design guys are dead wrong. Darwin was right all along (or maybe it's the pastafarians, but that's another topic). I experienced the living proof today that mankind has just spawned a new superior race that is going to dominate us all: The Boodhoo! The Boodhoo lives amongst us. He look like us. Breathes and eats like us. But he's different. The astute observer will be able to recognize him based on the following list of observations: He is always ...
If you use resharper with Visual Studio 2008, you may have noticed that it keeps suggesting you use implicitly typed local variable declaration i.e. the var keyword. To me, it is a bit annoying. You can actually find why people think it should exist in the first place:http://resharper.blog... There are some valid points, but I am not convinced. I think it is less readable in most of the case. I can’t agree with Ilya that it induces better naming ...
I've posted several new ReSharper tips of the Day to to Fooberry.com. One of the most interesting ones in my opinion is the ability for ReSharper to generate the overriden Equals method. Read more here at Fooberry.com.