TUX Update... (AKA I missed something)

MSDN Premium Subscription is up for grabs

I forgot to mention this yesterday. Bill Reiss our resident MVP is giving away an MSDN Premium Subscription. So if you come you have a chance at getting it.

Multi-location

BTW, we are working toward being multi-location, so if you are in another state in the US (probably more of an East Coast thing) or in Florida, one of our goals is to make our meetings available via streaming (but only to groups... sorry you won’t be able to just dial up our stream from your desk at home)

TUX (Tampa UX) is next Wednesday (Sept. 10th) at 6:30pm

The Tampa User eXperience User Group will have its first meeting next Wednesday. The presentation will be MS Ajax Client Script 101 by Jay E. Kimble (me). tux penguinWe will be meeting at  Answers Systems (4029 Tampa Road, Oldsmar, Fl 34677... right next to the Oldsmar Fleamarket).

Email me if you are planning on coming (use the contact form on the site). I will post my cell phone a day or two before (so you have someone to call in case you get lost).

Pizza and drinks will be supplied, so come on out.

CR/R! Wrap up

It’s been about a month since I took the challenge to replace ReSharper (R#) with Code Rush/Refactor! Pro (CR/R!). In that time I have adjusted well to CR/R!. There are a number of areas where I am MORE productive. Yep, I said that. There are a few things I miss (So Mark of DevExpress pay attention).

Code Analysis could improve

Code Analysis is a fairly new feature of CR/R! and as one would expect it’s not quite as strong as R#'s (I do expect this to get better, BTW). Sometimes it doesn’t find references to ASP.NET Server Controls from the Code Behind for instance which tends to make its analysis on ASPX CodeBehind files somewhat unpredictable. I also ran into some speed issues with JS code, but I think it was the network that day (because I haven’t had any issues since).

The other thing I love about R# is that not only does it analyze my code, but it gives me a convenient keystroke that helps me resolve the problem without having to leave where I am. CR/R! is building some of this stuff so we’ll have to wait and see what happens.

Embeddings

I still have a few embeddings that I would like to turn off (with no options to do so -- as far as I can tell)... I suspect I need to dig into the XML config files, but am scared to do so.

For the DevExpress Guys to note the main one I want to get rid of is called "Embed Not Parenthesis." What happens is that I’m in a long "if(...)" and I highlight the first "=" of an "==" (because I stupidly set it to "==" and not "!="), when I type "!" it translates my entry to "!(=)=" which would be nice is I had more than 1 character highlighted.

[If you don’t know what they are let me explain them. Basically with CR/R! if you have a section of code highlighted you can easily wrap that selection with say a region by typing CTL+3 (BTW, # = Shift+3 so the sequence makes sense); when you do that a #region/#endregion automagically wraps your selected code and drops you on the line to set the region text. ]

The embeddings in general could really benefit from a different set of key sequences. it’s too easy to highlight a section of code and accidentally type the single character that creates the embedding... I’d prefer a CTL sequence. Yes, I know I can change them myself, but the defaults make the product frustrating for newbies.

Wish List

Beyond what I have already mentioned I really have 1 wish. I want either an alternate set of keystroke shortcuts for things like Embeddings and single character templates [CR/R! has some single character templates that you type like "c{space}" and a class shell automagically appears] that I can set as the default (so choose something other than what has been the standard) or the ability to package up my settings and be able to easily share them...

Yes, Rory, I have thought about contributing an addin for your community project.

Script# Compatibility

BTW, CR/R! works with Script#! Well, I ran into a few minor difficulties, but I could use it with the product which is all I would have asked for. No crashes, and no real warts.

Final words

Well, the good news for the CR/R! crew is that I’m a convert. I waited too long for VS 2008 from R#, and in that time I realized that there is a different place to go to.

Finding that I can refactor all kinds of things (like HTML code and JS code as well as C# and VB code now if it only did Python... just kidding, Mark... I don’t need it) really sealed the deal.

If you are trying out CR/R! you should get the Rory’s latest zip file containing all the community plugins. You should especially install "Refactor_Resolve" from this zip file (You’ll want it!). This is the plugin that was written by Koen Hoefkens. BTW, these plugins I think all run with DXCore, so if you don’t have a license to any kind of Refactoring product then you might want to consider installing DXCore (it’s free) and then installing these plugins... they can make your life a little easier.

Red Gate & Reflector: My Concerns...

Ok, before I start off I want to note that Red Gate is one of our "Friends of TRT," so they show up on just about every page of the site (and would appear in every RSS if I had the time to figure out how to do it). I also want to note that I know that I am breaking a rule with this post and may alienate a vendor, but this needs to be said (and sometimes I can’t resist).

I love Red Gate tools. Their commercial stuff is absolutely awesome, and I mean that. If you don’t own at least their SQL Data/Compare tools, then you should. Their software engineering is without much fault (as far as I have seen). I love how they help the community (hence they are in our "Friends" program).

I was chatting with JP (John Papa) when I caught the news in the latest bulletin from them (it might have been old), and went from casual talk about John’s skin on his blog (see here) to "Crap! Red Gate just bought Reflector..." JP doesn’t necessarily agree with me, but I wanted to at least spit out what I’m bugged by.

Red Gate also owns the PInvoke.net addin for VS2005 (and maybe it now works with VS2008). When you click on the web site to get the addin you are prompted for an email address and are informed that you will be getting ANTS Profiler 3 and Exception Hunter 1 as well... so they bundled 2 trials with a free product... products that you may already have licenses to.

Not only that but every couple days you start getting spammed by their marketing department (it’s one of those... 2 days, 5 days, 1.5 weeks, 3 weeks, and after about a month they finally leave you alone). The bigger problem is that they don’t check their DB to see if you are already a registered licensee of a product (beyond the fact that you went there for a FREE PRODUCT).

So everyone is wondering if .NET Reflector will continue to be free. I know that it will... It will just be bundled with some stuff that you may or may not want... and then you’ll be marketed to for a couple weeks after... That would be my big complaint. I hope that they choose to do otherwise (right now you can still download just .NET Reflector... but the marketing guys haven’t had time yet to figure out what they want to do... so we’ll see what happens).

BTW, I hope I’m wrong about all this ... I really do. Red Gate is a company I really do like (I just don’t always like the way they have handled "free" products in the past)... I hope they continue to have a single download to the free product.

TRT Welcomes Back Dana Stevens

My friend Dana Stevens has decided to rejoin us (he was one of the original TRT members who never got a post up... I said he was just paranoid about being fired, but that’s me <grin />).

He already beat me to the punch and started blogging, so check him out.

Dana is a recovering "Pocket Protector" (Developer) who has sometimes masqueraded (in the past) as a "Black Turtleneck" (Designer). His expertise seems to be eclectic (much like my own), but he is specifically knowledgeable in matters of WCF, Services, and WPF (although he’ll probably be writing on the whole spectrum of software development subjects). In fact he and I often discuss REST versus WCF (I think that WCF can be overkill for what I can do with MS MVC + MVCContrib/RESTFul Services)... but enough of that...

Welcome Dana! Glad to have you back!

Review: Gurock SmartInspect

About a year ago, I was blogging at CodeBetter and I was given a product in hopes that I would review it. In fact I had won a copy of this product in the past. I promised and promised that I would take a look at it, but I never got around to it.

Mainly because I didn’t have a use (or thought I didn’t have a use) for a logging product at the time. Logging isn’t really all that "sexy" and I was trying to dive deep into all kinds of things.

Well, with my day job we ran into a some problems that after I analyzed the errors I realized that I was missing an important piece of the puzzle... So I started thinking about what I might need. Enter that product that I hadn’t had a chance to review...

Logging isn’t "sexy" or is it?

It’s only "sexy" when you NEED it. And when you need it you need something good. SmartInspect is really, really cool, and IMO after finally taking a day with it, I can say it’s also "sexy." It really brings your logging to life.

I’m an ASP.NET guy, so what I need is to be able to track a user through a site and see there path up to the error. SmartInspect allows you to create "sessions" of logs that follow a user via their session. You can also use a default session (if you are using something more single-processed/threaded).

You can colorize different things in the log and can even see the properties of an object that you throw into the log (you simply tell it to log the full object passing just the variable).

The best part for me was it was pretty simple. I did a fairly advanced thing with it in relatively short order (Sessions, logging our SQL calls), and it really wasn’t that much work. The code that you have to inject into your app (yes, you have to inject code into your app) is pretty trivial.

Remote Logging viewing

What I really liked was that the SmartInspect log console feels like VS and is a TCP/IP server which means that you can point an app at a machine to log via TCP/IP. The version that I was given even included source for the logging library (and I think everything else). Yes, you can log to a file and other more traditional log destinations... but the TCP/IP server is so "sexy."

Sold

Anyway, my workplace will be purchasing a copy of it... and it’s a tool you’ll probably need at some point. Here’s the web site (go check it out for yourself) - http://www.gurock.com/products/smartinspect/

BTW, it’s for Delphi, and Java, too.

Writing Better JS Components

Perry (my boss... a developer/manager... he codes and manages) and I have been having a recurring conversation lately. One that keeps bringing to my mind a product that I knew about when I worked for ZAC Catalogs (way back in the day). I would daresay that none of you had even heard of it (although we did pick it up as a result of Xtras carrying it, so maybe a few of you knew about it). I believe it was a called "MFC DataGrid Wizard" or something like that. Anyway what it did was build a custom DataGrid component for you based on selections in a wizard. You selected what features you needed and then it would take it’s full-featured Grid source code (which came with the component) and would dynamically generate a full blown component for you with just the features you needed.

There are two reasons this has become a topic for discussion for me. The first is that we are currently struggling with a set of third party components that a prior developer/manager pushed all over our main site. The components are ones that you have probably heard great things about them and they are pretty cool. The problem is when you shove these components everywhere! We are having ViewState issues among other things... One of the components is a full-featured Grid control (client-side) that while nice we usually only use as a glorified listbox (we use it for selecting an item). As a result I built a specialized DataGrid for our company (one that I’ll be doing a walkthrough on its codebase at the first TUX user group meeting next month)

The other reason is this post from Bertrand LeRoy where he talks about a simple grid for ASP.NET. Here’s my problem with Bertrand’s post. The grid he talks about as being simple really doesn’t sound all that simple to my ears. Let me list a couple features:

  • Column drag/drop
  • Different column types
  • Data Sorting/Paging
  • Inline editing

Now mind you these are awesome features if you need them all then you would want to use something like this, but a lot of times what we need is something simpler. You could use the aforementioned grid for this, but the grid will probably still use ViewState (because it needs it maintain state for the paging, sorting, and editing features). It might need several more scripts or <shudder /> it’s script might be 500-1000 lines longer because of the added features.

A Better Way

I have been thinking about a better way to "do" script components. We really need to have a wizard that asks us what we will be needing in the components and then the main script file can be customized (as can the server side code) to remove certain things. It could be done really easy with templates for the script. You need a template for the main file, and additional includes based on features. The server side would work pretty much the same way. I know that no company really wants to give away their source, but even if they were able to do this for script code that would make our lives a lot easier.

Core Addin Challenge: 2 weeks with CodeRush/Refactor Pro (CR/R!)

[As previously mentioned I have committed to switching from ReSharper (R#) to CR/R!... the end result will be a regular guy’s comparison of the 2.  DISCLAIMER: By no means is this meant to be a slight on R#, but more of me looking at CR/R! a little closer -- I think a number of us took a cursory look at CR/R! and while we found value a surface look doesn’t really give you the full picture... I’m going through the challenges of using CR/R! because it IS different from R# and hopefully I can help folks who are trying to compare between the two and decide which is best for their situation]

Turning the corner (sort of)

Tuesday I turned the corner I thought that there was no coming back (more on that in a second). The thing about CR/R! is that it’s truly a learning experience. CR takes over your environment in such a way that, while it still looks like Visual Studio, you need to re-educate yourself a little to all its nuances. It can actually get in your way (and there have been a couple times with Mark and Rory (and Koen HanHoefkens, the author of the excellent --and free-- CR_Resolve plugin) where I have asked "how do I turn xxx feature off." The most annoying one for me is that I tend to highlight code and start to overwrite with new code... for the most part there are no pains here, except when the character you type is a "(" which is often the character I am typing when changing an "if" statement. What happens is that this embeds your selection in a set of parenthesis.  This was actually easy to turn off... the feature is called "embeddings" which is found in the shortcuts section of the options (there are lots of options with CR/R!). Before I shut them all down I discovered some really rich stuff here... for instance you can highlight code, type "c" and your code is instantly surrounded by a try catch with your cursor setting in the catch block. I still turned off the parenthesis, but I left the rest of them on.

I’ve also started figuring out some of the templates.

I’m still learning here, but the topic is very deep!

BTW, I’ve found that this product enhances your experience while working with ASP.NET HTML, JavaScript, VB, C#, and even Script# (C# variant that creates JS files).

My One hiccup

I have experienced one hiccup over the last several days: PERFORMANCE/MEMORY FOOTPRINT. I’ve had VS crash a few times. I finally think I have the problem figured out (a not so well behaved plug-in I installed... I installed some really old plugins... well they didn’t seem that old).

Currently the only DXCore plugins I have running (besides CR/R!) are CR_RESOLVE, and the "Highlight Current Line" both from the community plugins (mentioned in the last post). I also have turned off the Code Analysis (temporarily).

I am still watching this closely (and am sure that Mark Miller will chime in either personally or publicly with a few more suggestions, but I don’t think he needs to... this lesson should be heeded that you need to be careful which addins you install in VS... they can make things run less than smoothly, and adding a bunch of them all at once makes it even harder to determine where the problem really lies).

101000

Well, this is the geek way to say this... today is the day... at approximately 8:10am est on July 31st, my official age is the equivalent of 1010 or $28 or written in another format : 0x28 (or in VB &h28).

That’s also 50 in octal (which really sucks! I think base 10 looks better than that don’t you think)...

[yep, I’m a geek... you can figure it out... to find that not only am I a geek... but an old one... I wrote all this the night before because tomorrow, I’m afraid that I will be cursed by the early onset of dementia and will have forgotten the whole thing as well as my birthday<grin />]

-----------

PS. I miss you mom.. I wish you were still here on this planet...

Core Addin Challenge: 1 week with CodeRush/Refactor Pro

[UPDATE 8/5: Rory noticed a couple spelling errors in people's names and also noted that I should give Koen HanHoefkens credit for his excellent CR_RESOLVE plugin]

I have survived my first week with CodeRush/Refactor Pro (CR/RP). I have discovered a few things about my development habits:

  • I don’t memorize all that many shortcut keystrokes... I tend to look for the "one keystroke to rule them all." Interestingly enough I avoid mouse usage as well
  • With the competing produce (R#) I use about 7 features:
    • Improved Intellisense
    • Rename Refactoring (which is also available in VS)
    • Extract Method (also available in VS)
    • Code Analysis
    • Auto-create add using/import
    • File Templates
    • Find Usages

I’m also discovering some things about CR/RP

  • I’m discovering that I need to tweak CR/RP’s default settings to avoid some of the "annoyances" (CR/RP can take over at times when you don’t want it to)
  • I think If I can get over the hump I am going to find that I’m MORE productive with this thing (although it has been touch and go at times)
  • One of my machines seems to run faster than R# and the other not so much (there are different things turned on/off on these machines right now)
  • RP provides more refactorings than any other product I have seen!! They even have refactorings for ASP.NET .ASPX files (the html part!!!)

So the "one keystroke to rule them all" for CR/RP is CTL + ~ . Oh yeah, you also need to install the community DXCore addin called -- Refactor_Resolve (which was written by Koen HanHoefkens and you can get from here.. but I would recommend that you get it out of the zip file found here. BTW, thank you Rory Becker for this info). Once you have installed that and get it turned on then Refactor! will give you an option to add usings/imports for your unresolved references.

Oh yeah that community project has a number of nice things you may want to install... like the highlighted line focus.

As I mentioned before you also need to turn on Code Analysis and cut down the size of the little bar at the bottom of the code files, by setting it to 1 file and 0 pixels (it will still show up, but it won’t be as intrusive... your scroll bar will work again). One more thing I believe this feature is a new one (and maybe even a beta one)... it’s not as good as R#'s but from what I understand with their plans it is going to get a lot better (they are going to add over 100 items it can check for and find...)

Additional things I did was I turned off the Smart Brackets and Smart Parentheses and the some of the Smart Paste features features (the auto create properties ones are what I killed... I may kill a few more of the Smart Paste features to get things tweaked out a little better for me).

Summary
All in all things are getting better... Today was a breakthrough day for me (Thank you Rory Becker and Mark Miller)! I think I turned the corner on my experience. I’m think I’m as productive with CR/RP now as I was with R#. I’m only missing 2 things... both of which are livable right now: Find Usages (which I can use the Find References mechanism), and R# File Templates (but CR’s templates are WAY better... so I need to learn a few more of those... I have a number committed to memory already). Just 23 more days to go... but I suspect I'm going to be very comfy before that happens.