The CodePlex site does a good job of describing all commands. For those who want to dive a bit deeper, there’s a blog post that describes installation and the finer points of usage. The post is written in an Asian-looking language but there are lots of images that tell you all you need to know.
Monday, November 2, 2009
Friday, October 16, 2009
You can design interactions like showing, hiding, or animating (to name just a few) elements based on user actions (like clicking on an element). The design work is done by selecting elements and setting properties for actions, reactions, … The finished script can then be exported for inclusion in your web page.
IxEdit uses Google Gears and local database storage to save you work – that means that you’ll still have your lovingly crafted interactions after the html page is refreshed.
Friday, September 25, 2009
In my previous post, I talked about StyleCop and how it helps you to enforce a consistent source code style throughout your project. However, StyleCop only flags violations but does not fix them – even though most of the times the fix is trivial.
StyleCop for ReSharper includes an automatic update detection mechanism and will prompt you if a new version is available.
Most people agree that having a consistent coding style throughout a solution is beneficial to the development process. In the past it has been difficult to enforce a style, though. StyleCop is one answer to that problem.
StyleCop – the tool formerly known as Source Analysis – is a tool that analyzes C# code and warns about violations against “a common set of best practices for layout, readability, maintainability, and documentation of C# source code.” It can be run from inside Visual Studio, and can also be integrated into MSBuild scripts.
When run inside Visual Studio, StyleCop integrates with the Error List tool window, and double-clicking on a warning will take you to the appropriate spot in your source files.
It is possible to configure which rules StyleCop should check, however it is not possible (yet) to modify existing rules or define your own rules.
StyleCop can also be used as part of your build process using the out-of-the-box MSBuild integration.
GhostDoc is a plug-in for Visual Studio that can automatically generate XML comments. GhostDoc uses a configurable rule set to derive meaningful comments for constructors, events, properties and events.
For example: XML comments for constructors should start with “Initializes a new instance of the <classname> class.” GhostDoc can automatically generate that comment.
A method called “button1_Click” will be commented with “Handles the Click event of the button1 control”, complete with comments for the parameters.
A property “NameOfTheUser” will be commented “Gets or sets the name of the user”.
The rules of GhostDoc can be extensively customized, but in my experience this usually isn’t necessary because the default rules are pretty good.
One disadvantage of GhostDoc is that there is no official support for documenting an entire class (or project or solution) at once. There is an unofficial Visual Studio macro that does exactly this, though: http://jb-brown.blogspot.com/2008/09/using-ghostdoc-in-macro-to-comment.html.
Friday, August 28, 2009
MeasureIt is a Firefox that enables you to measure the size of parts of the page you are viewing. MeasureIt shows up as a small button in the lower left corner of the Firefox window.
When you click on the button, the browser window will be overlaid with a whitish layer and the cursor turns into a cross. Click and drag the cursor over the area you want to measure.
A floating element will show the size of the select area. Clicking on the red square with the white cross will close the ruler but keep the whitish overlay. Pressing Esc on the keyboard removes the overlay.
Screengrab is a plug-in for Firefox that enables you to take a screenshot of (part of) the current web page. You will find Screengrab in the lower right corner of the browser window.
You can either save the screenshot to a file or copy it to the clipboard.
WCAG ColorChecker is a Firefox plugin that enables you to test the colors of a web page for easy readability with regard to contrast and several Discromatopsia. It installs itself as a button in the lower left corner of the status bar. Clicking on the button opens a side panel. You can select elements or colors on the page using ColorZilla, and ColorChecker will show you its results using either a green check mark or a red cross next to the criteria.
ColorZilla is a Firefox plug-in that enables you to determine which color an element on a web page is using. Click on the Eyedropper tool in the bottom-left corner of your Firefox window. The cursor will turn into a cross and the html element you’re hovering on will have a red border. The color values of the element you click on will be added to the status bar.
ColorZilla also contains a color- and palette-manager. You can open it by right-clicking anywhere on the page, pointing to ColorZilla and selecting either Color Picker or Palette Browser.
Not everybody is happy about this plug-in being installed automatically. In addition the plug-in cannot be easily uninstalled because it is a computer-level plug-in. There is a documented way of uninstalling it, though: http://support.microsoft.com/kb/963707/.
IE Tab is a plug-in for Firefox that enables you to display web pages in a Firefox tab using the Internet Explorer rendering engine. This enables you for example to quickly compare different rendering behaviors or run Microsoft Update from Firefox.
Tabs being viewed using IE Tab don’t display the normal favicon of the site but rather the IE logo. In the screenshot below the left tab uses the Firefox rendering engine while the right tab uses the IE rendering engine.
HttpFox is a Firefox plug-in that enables you to monitor HTTP traffic made by the page you are viewing in Firefox. Its functionality is similar to Fiddler, but is a “native” Firefox plug-in.
An additional advantage over Fiddler is that HttpFox can watch traffic to localhost as well.
FiddlerHook is a Firefox plug-in that enables you to use Fiddler with Firefox. You will first need to enable FiddlerHook in Firefox (menu Tools –> Monitor With Fiddler –> Use Fiddler Automatically). Then add a Fiddler button to the navigation bar by right-clicking and selecting Customize. Drag the Fiddler button to the navigation bar, click done and click on the Fiddler button.
HttpFox is similar to Fiddler, and is a “native” Firefox plug-in.
An interesting advantage of using Fiddler through Fiddlerhook with Firefox when compared with Fiddler with Internet Explorer is that you can watch traffic to localhost.
PS: you can use Fiddler in IE if you set Fiddler as proxy for IE.
Friday, August 21, 2009
In Visual Studio Team Explorer it might be useful to create copies of work items to start with instead from creating a new one from scratch. Especially if you run two parallel systems with similar issues: e.g. a ticketing system for customers and a bug tracking system for the development.
You can by opening the work item in question and then use the Create Copy of Work Item… command in the Edit menu:
or in the context menu of the work item:
After clicking, the Copy Work Item dialog appears and you can determine the team project that you want to copy the work items to.
See further information, especially on the implications of the selected Work item type, here.
Depending on the current view, there are three different meanings of CTRL+G:
- in the editor view the Go To Line dialog pops up and you can jump to the entered line number:
- when dealing with work items, the Go To Work Item window pops up and you can navigate to a particular issue:
- in the source control view, CTRL+G opens the Find Changeset dialog which allows you to query for change sets:
Sunday, August 16, 2009
Current Site IP is a Firefox plug-in that shows the IP address of the site you are currently viewing in the status bar. This is especially useful when there are separate development, test, staging and production environment and you have to switch between them using host file entries.
XPather is a plug-in for Firefox that shows you the xpath expression for selecting an element on a web page. You can open it by right-clicking on an element and choosing “Show in XPather”. You can then edit the xpath expression; if the expression matches multiple nodes all those nodes are shown in a table.
YSlow is a plug-in for Firebug (which is a plug-in for Firefox) that will analyze your web page and make recommendations on how to improve its load time. YSlow is developed by Yahoo and is similar to Google’s Page Speed.
PageSpeed is a plug-in for Firebug (which is a plug-in for Firefox) that will analyze your web page and make recommendations on how to improve its load time. Page Speed is developed by Google and is similar to Yahoo’s YSlow.
FireFinder can use XPath expressions as well. XPather offers much more XPath functionality, though.
Firebug is a plug-in for Firefox that enables you to inspect the DOM of the web page that you are currently viewing. It also enables you to inspect the CSS styles of any given element, and trace those styles back to their definitions in CSS files. There is also a script debugger and a console.
Note: if there is no “Develop” menu in Safari, you can enable it using Setting button –> Preferences –> Advanced –> Show Develop menu in menu bar.
Friday, July 31, 2009
In Visual Studio there is a feature called Annotate. In the Solution Explorer just right-click on a source code file and select Annotate. The result will be a view of this file where you have meta information for each line of code:
- who did the latest change
- when was it done
- which changeset contains this modification
This can be useful in a code review or other situations where nobody remembers (or wants to remember ;-) who did the modifications.
It depends on your architecture how easily you can debug the code running a Windows Service. Most propably you use a layered architecture which allows you to directly call the code doing the critical work. E.g. by a Winforms test application or via a administrative page in your web application.
But what if you have to find out what is going wrong in the service infrastructure itself? I usually install the service on my local machine directly from my <Service>\bin\Debug folder. Of course you will always have to make sure the service is stopped if you want to rebuild.
When running the service you can attach to the process and hopefully are fast enough to step in at the critical part of your code. Otherwise you can use the Debugger.Launch() method. I would suggest to put this call into the OnStart() of the service or into your Start() block :
When the framework executes the Debugger.Launch() method and prompts you to select the debugger, select the VS instance that shows the service code and continue to run the service under the control of the debugger.
Be careful that the debugger dialog does not show up in a released version. To avoid this you can check with #if DEBUG or use command arguments which you provide in the service properties:
Alternatively implement a while-loop which waits for the debugger to be attached. You can find a code snippet here.
In Excel, the Transpose function returns a transposed range of cells. For example, a horizontal range of cells is returned if a vertical range is entered as a parameter. Or a vertical range of cells is returned if a horizontal range of cells is entered as a parameter.
This can be useful especially if you have to copy rows from a database with a large number of fields. The transposed row-oriented result may be easier to read as the default column-oriented view:
- Highlight the cells that you want to copy.
- Then right-click on the cell where you'd like to paste the values and select Paste Special from the popup menu.
- Then select the Transpose checkbox and click on the OK button.
Wednesday, July 15, 2009
A few weeks ago I sketched some waves that got high in the community concerning an in the first glance not so friendly episode of the StackOverflow Podcast (see post “A Solid Audio Rant”). Besides other topics, Joel Spolsky and Jeff Atwood, the guys performing on that podcast, talked about the SOLID principles advocated by Robert C. Martin (aka Uncle Bob).
Now by chance I found a letter that Uncle Bob published on objectmentor.com in reaction to the offensive StackOverflow-Episode: An Open Letter to Joel Spolsky and Jeff Atwood.
And that letter is really interesting if you just listened to the podcasts I mentioned in my earlier post. Because in that podcasts the climate changed from ranting to an almost esteeming atmosphere. But as we now can read from that letter mentioned above, Mr. Martin’s first reaction was not so friendly by really harnished (up to menacing steps towards legal contention).
So, check it out!
Sunday, July 5, 2009
Most of you will recognize the UI of this Tool from way back: like NortonCommander or MidnightCommander but TotalCommander is a really well done Port for the Windows-World and was already available in the Win3.11 times: and this is actually the one and only weakness: it looks rather old :)
Compared to its advantages, you might forget the Surface:
- TabStructure: you can save your most used places as tabs and get them everytime the TC starts (lazy loaded for network/external devicec)
- Splitted Screen to work with 2 folders in parallel
- Queued copy/move for Files: no more blocking/slowing down parallel copyjobs (esp. for network transfers!)
- Custom Fileassociations besides "open"
- Integrated FTP/WEBDav: no use for special FTP-Software
- Copying fully qualified filenames in the clipboard
- Integrated RAR/ZIP handler
- A large repository of plugins (Filesystems, Tools, etc.)
- Showing all files in Subfolders
- MultifileSelection via Wildcards/Regex
- Multirenaming via Wildcards/Regex and common statements (Date, etc.)
- Folder Synchronization
- Commandline in the active Folder
- File Splitting/Encoding/Hashing
- fully customizable hotkeys
- and a lot more!
Note: if you want to use it in an 64bit environment, I would suggest to try the current betaversion (7.50 beta6)
Friday, July 3, 2009
In a previous post, Sebastian drawed our attention to a nice selection expansion feature of ReSharper. I also think this feature is cool, and want to present it here in more depth.
Visual Studio by itself supports the expansion of the current selection in a text editor window by pressing Ctrl+W.
With this command you can change a current selection like this …
… to a selection of the whole word:
If your existing selection spans several words like this …
… after pressing Ctrl+W you end up with the word selected that is at the end of the selection:
(Funnily, if you made your selection from right to left the left word gets selected:
Further pressing Ctrl+W does not do anything more.
Text Expansion With ReSharper
ReSharper has taken that expansion feature to the max (that’s why we love this tool!).
Beginning with no selection …
… by pressing Ctrl+W ReSharper selects the whole word:
But now, you can press Ctrl+W several times more to expand the selection to several areas, one larger than the one before.
From the single word selection you get the selection of the whole string without the quotes:
Then ReSharper selects the string including the quotes …
… then the whole concatenated string from the beginning of the expression …
… and then incrementally the whole string expression line by line:
And so it goes on with every stroke on Ctrl+W until the whole file content is selected:
The whole statement …
… the whole block without the braces …
… the block including the braces …
… the whole member …
… the type’s content without the braces …
… the whole namespace’s content without the braces …
… the whole namespace …
… and finally the complete content of the file:
As you may guess, the whole stuff can be done in reverse order pressing Ctrl+Shift+W.
Good to know!