Blog

  • Adding a Code Snippets path located on a network drive

    By in .NET, Code Snippets on

    I just got an e-mail referring to my Code Snippets – the whole enchilada blog post. The question was how you can add a Code Snippets path which is located on a network drive.

    Here is how it works:

    • Open up regedit.exe
    • Go to HKEY_LOCAL_MACHINESOFTWAREMicrosoftVisualStudio8.0LanguagesCodeExpansionsCSharpPaths
    • Edit the Microsoft Visual CSharp entry and add the desired path to where the Code Snippets are located separated by a semicolon.
      You can either use a mapped network drive or use the network path directly.

    You can of course use a .reg file to import the new path. Here is an example for that:

    Windows Registry Editor Version 5.00

    [HKEY_LOCAL_MACHINESOFTWAREMicrosoftVisualStudio8.0LanguagesCodeExpansionsCSharpPaths]
    "Microsoft Visual CSharp"="%InstallRoot%\VC#\Snippets\%LCID%\Visual C#\;%InstallRoot%\VC#\Snippets\%LCID%\Refactoring\;%MyDocs%\Code Snippets\Visual C#\My Code Snippets;<my new Snippets path>"

    Replace the <my new Snippets path> placeholder with your desired path and save this to a file with the .reg extension. Remember to double the number of backslashes for escaping purposes. So for a network folder like \MyServerMySnippetsFolder you have to use \\MyServer\MySnippetsFolder in the .reg file.

    After doing so, every Code Snippet located in the added folder will automagically be added to the list of available Code Snippets. You don’t even have to restart Visual Studio after adding new Code Snippets. You can also add subfolders and place your Snippets there. The subfolders will also be added automaticaly.

    Here comes the “but” as nearly always: The strange thing is, that you have to add this path to the “LOCAL_MACHINE” section to the registry. Adding the same path to the “CURRENT_USER” section had no effect.

    Read more
  • Vista: How to replace Notepad

    By in Tools, Vista on

    Oh my, it’s been so long since my last post. Since beginning to learn playing the piano about 8 weeks ago, I unknowingly shut down my blogging activities. Well, let’s restart this blog with a small Vista centered post.

    I guess most of you will agree, that the integrated Notepad isn’t really the big bang, right? App. 3 years ago Roland blogged about replacing the standard Notepad with the really nice Notepad2 in Windows XP SP2. Today I will show you how to do that in Windows Vista.

    How-To

    Notepad.exe resides in two places:

    • c:windows
    • c:windowssystem32

    You have to replace it at both locations performing the following steps:

    • Make sure that you are logged in with an Administrator account
    • Change the owner to the current account or the Administrators group
      • Right click on notepad.exe
      • Select Properties
      • Select Security tab
      • Click on Advanced
      • Select Owner tab
      • Click Edit
      • Select the current user or the Administrators group in the Change owner to list
      • Close all dialogs with OK
    • Set Full control rights to the current account or the Administrators group
      • Right click on notepad.exe
      • Select Properties
      • Select Security tab
      • Click on Edit
      • Select the current user or the Administrators group in the Group or user names list
      • Activate the Full control Checkbox in the Permissions for Administrators list
      • Close all dialogs with OK
    • Rename notepad2.exe to notepad.exe and replace the standard notepad.exe by overwriting it
    Read more
  • FedCon XVI – I had a blast!

    By in Useless stuff on

    Stardate -315565.6 … Bonn/Germany … these are the voyages of Jens Schaller visiting his first Star Trek Convention…

    After talking about visiting a Star Trek Convention for nearly 20 years, I finally did it. I visited the FedCon XVI in the Maritim Hotel in Bonn, which isn’t very far from my home.

    Yeah, I know there are some – or maybe some more – of you thinking: “A Trekkie Convention? That’s some place for weirdos, right?”. Well, I just thought nothing and had no special expectations. I just wanted to have a good time seeing some of the stars, etc.

    But what I experienced there was beyond any imagination! My recommendation is: If you ever saw the different series of Star Trek and liked them, go visit a Convention, you’ll love it!

    Without anymore babbling I’ll try to give you a few impressions:

    In each Spaceship of Star Trek there have to be Jefferies tubes, right?
    Seeing a group of app. 15-20 Imperial Stormtroopers passing by really is something. Captain Jack Sparrow and his crew were there too and Jack got the audience award for the best costume. Not to mention his mimic 😉
    Jonathan Frakes aka Commander William Thomas “Will” Riker entered the stage singing with an italian accent: “Voooooooooooolaaaaaaaaaarrrreeeeeeeeee” and the whole audience answered: “Ooooooooooooooohhhooooooooooooooo”.

    Later on he replayed a scene on the bridge when the ship was attacked. The camera shakes and the actor had to shake too. Frakes playing Patrick Steward as Captain Jean-Luc Picard mumbling: “25 years in the Royal Shakespeare Company for THIS…”

    The costume contest was awesome (at least most times). Here’s a scene of Kosh and Delenn out of Babylon 5, where Kosh reads a Vogon poem straight out of the Hitchhikers Guide to the Galaxy.

    Jewel Staite (Kaylee Frye from Firefly/Serenity) und Laura Bertram (Trance Gemini from Andromeda) did a panel together. If have to say that I did only watch one or two episodes of Andromeda and found it awful, but Laura in person is fabulous. Someone in the audience got it to the point: “I have never seen Andromeda, but if your role is nearly as great as you are, I have to watch it.”

    When asked by another person in the audience, which unusual question the both would like to be asked and also would like to answer, silience occured.

    After a few moments Laura asked Jewel with a squeaky kind of voice: “Jewel, what’s your favourite Jellybean flavour?”
    Jewel: “Watermelon”
    Laura: “Now THAT was an unusual question.”
    Jewel: “Now Laura, what’s your favourite animal?”
    Laura (again with that voice): “A seahorse…” “And do you know why?”
    Jewel: “No?”
    Laura: “Because the men have to carry out the babies…”
    The audience was rolling on the floor laughing 😉

    Garret Wang alias Ensign Harry Kim (Voyager) is really some comedian.He told us, that he nearly ran over Harrison Ford when arriving on his first day for filming Star Trek Voyager. He thought about the possible headlines in the newspapers: “Star Trek rookie kills Han Solo

    He also told us about the (internal) nickname for Jeri Ryan aka Seven of Nine: “2 of D”

    Some more laughs came for the Elbow Story (see: The Anatomy lesson) and the Shaking Practise (“The DS9 guys REALLY know how to shake”).

    Kate Mulgrew (aka Captain Kathryn Janeway) had a great presence on stage. She is a very intelligent, but also thoughtful person with a great sense of humor. The “Spitball Story” was just gorgeous, but to long to tell here.She and Armin Shimerman aka Quark (DS9) were the only ones getting standing ovations and they absolutely deserved it.
    Well, without much words: Me and the sweet and wonderful Laura Bertram.After signing a photo I did the day before, she asked for my web address for taking a look at the other pictures in the FedConXVI gallery.

    On Saturday night there was a big party with great people to meet and Cirroc Lofton and Anthony Montgomery performing some live Hip-Hop/Rap songs. Star Trek fans really know how to party.

    You really can’t describe what is happending to you when visiting such a place. It seems like you are leaving the real world entering another for nearly three days. There is something in the air that sucks you in and you need a while to adjust after it. I guess “Reality Jetlag” would be the perfect expression for it.

    I leave you now with a photo of the closing ceremony, as always hosted by the fabulous Marc B. Lee, and I hope you enjoyed the little flight through the FedConXVI. It was a wonderful weekend with lots of nice people. Special greetings go to Kathrin and Any.

    For more photos, feel free to visit the FedConXVI gallery.

    ~Jens

    Update: Due to a current incident, I decided to password protect all photos in the gallery. Please drop me a line, if you’d like to gain access.

    Read more
  • GhostDoc 2.0.0 Released

    By in .NET, Tools on

    After quite a long time Roland Weigelt (a colleague of mine) has just released a new version of GhostDoc.

    GhostDoc is a free add-in for Visual Studio that automatically generates XML documentation comments. Either by using existing documentation inherited from base classes or implemented interfaces, or by deducing comments from name and type of e.g. methods, properties or parameters.

    Some of the new features are:

    • Support for Vista out of the box
    • Support for Orcas (tested: Beta 1)
    • Better support for generics, more language elements, new rules, new macros

    This is one of the must have add-ins for Visual Studio. If you don’t know it, jump to the GhostDoc Website and give it a try!

    Read more
  • Folien zum Vortrag “Visual Studio anpassen und erweitern”

    By in .NET, Code Snippets, Development on

    Nachdem Roland Weigelt und ich am letzten Montag bei der .NET User Group Paderborn einen Vortrag zu den Anpassungs- und Erweiterungsmöglichkeiten von Visual Studio 2005 gehalten haben, sind die Powerpoint Folien nun auch als Download verfügbar.

    Es hat riesigen Spaß gemacht vor den 15 anwesenden Zuhörern zu referieren. Vor allem wenn man bedenkt, dass angesichts des prima Wetters die meisten Paderborner den Abend in den Wiesen an der Pader genossen.

    Read more