April 2006 Entries
Nice collection of samlple code for Visual Studio 2005 both in C# an VB.Net. http://msdn.microsoft.com/vstudio/downloads/101samples/default.aspx. The samples include:
Changing ACL (Access Control Lists) on files
Console Enhancements including buffer control, simple animations and colors
Downloading files using FTP (File Transfer Protocol)
Network Programming including PING, UDP, and TCP network statistics
Using the new Stopwatch class to measure time
Compressing and decompressing files in the GZip format
Retrieving Drive Information
Using Generic Collections
Creating Regular Expressions to parse text
Building a tracing infrastructure to track errors and application performance
Controlling cache policies with the new System.Net.Cache namespace
Creating a process viewer
Creating a...
I needed to unit test a method that retrives a value from a custom property on a Microsoft Content Management Server posting. This is how I did it:[Test]
public void GetLanguage_GetLanguageFromPosting()
{
using(CmsApplicationContext appCtx = new CmsApplicationContext())
{
appCtx.AuthenticateAsCurrentUser( PublishingMode.Update);
try
{
Template templ = appCtx.Searches.GetByGuid ("{8DD8B72A-31B7-495B-80F9-1319FAA78BF2}") as Template;
...
Found a nice tool for giving a good overview of what is taking your disk space. Displays the result in a treeview and a treemap. Gives a really good overview. The tool is WinDirStat.
If you've been working with Microsoft Virtual PC you probably noted that the virtual hard disks (.vhd files) tend to bulk out on your host drive. So here is a little tip to help with this, that I just discovered.
From within your guest OS, Capture ISO... and point to C:\Program Files\Microsoft Virtual PC\Virtual Machine Additions\Virtual Disk Precompactor.iso
When AutoPlay starts up the iso, you'll get a dialog asking you if you want to prepare the virtual hard disk for compaction. Which you of course want to
When that is done, follow the instructions and shut down the guest OS
From you host OS,...
Microsoft Content Management Server 2002: Security Best Practises now available at: http://www.microsoft.com/downloads/details.aspx?FamilyId=473BEA55-08C1-439E-BA7F-698E5EC343ED&displaylang=en.
Overview:
This download consists of a security white paper and the 'Minimum permissions' batch script. The white paper explains how IT administrators can apply security best practices to Microsoft Content Management Server (MCMS) 2002 Service Pack 1a (SP1a) environments. It includes sections on MCMS security fundamentals; securing MCMS 2002 environments; advanced security information such as port numbers, minimum NTFS, and registry permissions; script samples; and links to additional information. This advanced level paper assumes readers are familiar with the fundamentals of MCMS, Active Directory, and Microsoft Windows Server 2003....
Ever written a .bat-file to do som deploying or such. It's usally a lot of cd ..-ing to get to the right path and keeping track of the path. I have. So reading Scott Hanselman's blog his post turnd me on to pushd and popd.
This is awsome, you can keep a stack of directories. Here's an example:
Nice eh!
This Monday I attended a course on how to work more effective in Outlook. The course is based on the philosophy in The 7 Habits of Highly Effective People by Stephen R. Covey. So it's not all about Outlook YOU have to change some things to :).
The first thing we did when cranking up Outlook was to remove all "you've got mail" sounds and pop-up boxes etc. I only had them off for two days now but man do I like it! I'm able to work more efficient without these interruptions. Cause when that box popped up I just had...
Very often when starting out a new project with a backend database I have usally forgotten exaclty how to compose a connetion string. So, what do I do?
Create an emtpy text file someware, reneame it to .udl (instead of .txt). Open it up by double-clicking it and use the dialog to get your connection up an running.
And then just open it up in your favorite text editor and there you have your connection string. You probably have to clean it up a little.
As I wrote in my previous post I changed my blogging software. In order to migrate all posts and comments from my previous blog i wrote a little program to do it. I did not read a lot of documentation on how to do this, strictly a trail and error approach.
I started out by looking for what web services the different blog systems exposed by doing a file search for *.asmx and just pointing my browser to then to have a look at the API's.
For dasBlog the one that cauth my eye was /SyndicationService.asmx and for SubText it was the...
So, I've just changed my blogging software from dasBlog to SubText. Why? Hum, cause I felt like change. I tried to install SubText, wich by the way was almost to easy, and I liked what i saw. Change is good for you!
I'll keep the old blog available for a while at http://www.nnihlen.com/dasBlog until I'm sure I haven't missed anything in the migration process. Speaking of migrating I wrote a little hack for doing exactly that wish I will be publishing on my(this) blog soon.
I do apologize to thoose of you syndicating my blog (all 3 of ya..) :).