Sunday, April 26, 2009

DevTnT 3 - TechTalk's preferred file editors

We asked our colleagues for their preferred file editors - here are the results:

Notepad++

  • freeware
  • syntax highlighting and auto completion for several programming languages
  • plug-ins can be installed (e.g. XML Path Plugin: mouse right click shows the path of an XML element, Hex Editor)
  • multi document
  • column mode selection
  • download at http://notepad-plus.sourceforge.net/de/download.php

Notepad2

Wordpad

  • ships together with Windows
  • allows you to open huge files

Ultraedit

  • license (free trial)
  • most powerful editor with many features (e.g. provides an ftp-client)
  • download at http://www.ultraedit.com/

Friday, April 24, 2009

DevTnT 3 - Change Editor for View Source Code in IE

You can change the IE7 view source editor pretty easily to any of your favorite tools by hacking up the registry. Maybe you want to backup the Windows registry first.In regedit navigate to HKEY_LOCAL_MACHINE –> Software –> Microsoft –> Internet Explorer and create a new key named "View Source Code Editor". Below this key, create another one: "Editor Name". Double click the default value of the Editor Name in the right pane and enter your tool including the complete path:

DevTnT 3 - Visual Studio: Show active file in solution explorer

One of the annoying things about Visual Studio default settings is the fact that the Solution Explorer does not track what files you are currently looking at. There is actually a setting in Visual Studio that does this automatically: Tools - Options - Projects and Solutions - Track Active Item in Solution Explorer.

DevTnT 3 - Newbie at ReSharper?

Are you new at ReSharper and want to get a quick overview about navigating your source code? Have a look at http://www.dimecasts.net/Casts/ByTag/ReSharper for a nice screencast.

DevTnT 3 - Administrating a Group Chat on Skype

With Skype 4+ you can not only create group conversations but also save them. Contacts - New Group displays a dialog where to create the group. After adding members click on the symbol on the top right in order to provide a name and store it.

Now you have an entry "my group chat" in the contacts list and are able to see the history of this conversation.

DevTnT 3 - Ctrl+Del: Delete to end of word

In Visual Studio and many other Windows applications you can use CTRL+DEL to delete the word to the right of the cursor. If you’re in the middle of a word, it only deletes the portion that’s to the right of your cursor.

At least in Visual Studio with SHIFT+DEL or CTRL-X the complete line can be deleted. The content is put to the clipboard. CTRL+D duplicates the current line. For cutting a line after the cursor there is no single shortcut: you have to press SHIFT+END for selecting the rest of the line. Then use DEL for deleting the selection.

DevTnT 3 - Delayed delivery in Outlook

See our previous post http://devingdever.blogspot.com/2009/04/devtnt-2-ctrlenter-send-e-mail-in.html for delaying the delivery of emails.

Sunday, April 12, 2009

DevTnT 2 - Sharing or saving ReSharper coding conventions

The ReSharper coding styles can be exported and imported by ReSharper - Options - Common - Code Style Sharing - Import/Export. (Code inspection severities are said not to be supported by this feature yet.)
This will create a file next to the Solution called project.4.1.resharper. The file has to be added to the source control.

For details on sharing across the team with TFS see the posting from Michel Grootjans: http://geekswithblogs.net/alternativedotnet/archive/2008/10/20/125936.aspx

DevTnT 2 - Sharing or saving Visual Studio settings

Settings in Visual Studio consist of customizations made to the integrated development environment (IDE) based on different types of development activities and your own customizations.
In Visual Studio use Tools - Import and Export Settings... - Export selected environment settings. For importing an existing profile use the Import option.

The main purposes we collected and which are mentioned by Microsoft as well are:
  • Create a copy for use on a second machine or if you re-install your system
  • Share your active settings with a team
  • Allow all team members to use the same settings in select areas, such as the editor, without removing individual customizations to other areas
Further reading: http://msdn.microsoft.com/en-us/library/zbhkx167(VS.80).aspx

DevTnT 2 - Refactoring easily applied with R#

To perform a refactoring, select an object or a code fragment you want to refactor. Then click ReSharper - Refactor - Refactor this or press Ctrl + Shift + R to open the list of refactorings that can be applied to the selected object or code fragment, and then select the necessary refactoring.

DevTnT 2 - Unlocker helps deleting locked files

Unlocker application was designed to be a useful Windows Explorer extension allowing users with a simple right-click on a file or folder to easily get rid of error message such as error deleting file or folder, cannot delete folder.

It helps delete locked files with error messages like

  • Cannot delete file: Access is denied.
  • There has been a sharing violation.
  • The source or destination file may be in use.
  • The file is in use by another program or user.
  • Make sure the disk is not full or write-protected and that the file is not currently in use.

If the folder or file is locked, a window listing of lockers will appear:

This freeware tool can be found at
http://www.softpedia.com/get/System/System-Miscellaneous/Unlocker.shtml

Friday, April 10, 2009

DevTnT 2 - Ctrl+Enter: Send e-mail in Outlook

When sending an e-mail in Outlook, don’t bother clicking on that “Send” button — press Ctrl+Enter to send. You’ll need to confirm with a dialog box the first time. The Shortcut Alt-S also works.

Some people complain as they send a vital email by accident before it was ready. Maybe this can be solved by using some built-in features of outlook: You can delay the delivery of an individual e-mail message or you can use rules to delay the delivery of all messages by having them held in the Outbox for a specified time after you click Send. For further details see http://office.microsoft.com/en-us/outlook/HP012328171033.aspx

DevTnT 2 - How to switch Control and Capslock keys

The Caps Lock key on most PC keyboards is in the position where the Control key is on many other keyboards, and vice versa. This can make it difficult for programmers to use the "wrong" kind of keyboard. This posting shortly describes how to swap these two keys.

Make a file named (for example) CapsLockIsCtrl.reg with these three lines:
REGEDIT4
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout]
"Scancode Map"=hex:00,00,00,00,00,00,00,00,02,00,00,00,1d,00,3a,00,00,00,00,00
Double click it from Windows explorer, reboot.

To put it on the Left-Ctrl key use SwapCtrlAndCapsLock.reg:
REGEDIT4
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout]
"Scancode Map"=hex:00,00,00,00,00,00,00,00,03,00,00,00,1d,00,3a,00,3a,00,1d,00,00,00,00,00

Alternatively you can manually manipulate the registry by adding the key "Scancode Map" under HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\Keyboard Layout and enter the hex codes mentioned above:

DevTnT 2 - Why is my harddisk full and wtf is WinDirStat?

WinDirStat (WDS) is adisk usage statistics viewer and cleanup tool for Windows. It shows disk, file and directory sizes in a treelist as well as graphically in a treemap.

This open source tool can be downloaded for free under http://sourceforge.net/projects/windirstat/

Similar freeware tools are

DevTnT 2 - Create a Visual Studio Shortcut for "Open Containing Folder"

There is something you do a lot in Visual Studio and there is no shortcut for it? Create one. You have to

  • Choose Tools - Options - Environment/Keyboard
  • Type in something into "Show commands containing" to get a list of matching commands. If there is already a shortcut for the selected command, it’ll be displayed in "Shortcuts for selected command".
  • To assign a new shortcut to the selected command, put the cursor in "Press shortcut keys" and press the shortcut key or key combinations desired. E.g. you can want to open the containing folder of the current file in Windows Explorer by pressing Ctrl+Shift+Alt+O?

DevTnT 2 - Ctrl+Backspace: Delete to previous word

If you’re typing (in Word, Outlook, PowerPoint, and many other text entry programs) and you use the wrong word, a quick way to delete the entire word is Ctrl+Backspace. If you’re in the middle of a word, it only deletes the portion that’s to the left of your cursor.