Build an XP SP3 Recovery Disc
Shared via AddThis
Saturday, June 6, 2009
Friday, May 1, 2009
The World Is Flat
I came across this video while browsing through MIT’s open courseware. An excellent lecture by Thomas L. Friedman form 2005 about everything from the start of Netscape to outsourcing, politics, software etc. Its startling how relevant this talk still is and what a visionary he is.
More here http://mitworld.mit.edu/video/266
Thursday, April 16, 2009
C# TitleCase function doesn’t do the job
The TitleCase function in C# doesn’t always work if you don’t provide the CultureInfo string e.g “en-US”. But even when you do, it does not correctly format strings such as McDonald or O’Connor. The title case function would just return Mcdonald or O’connor. The following function correctly capitalizes the appropriate letters and will also exclude letters from the string that should not be capitalized.
For instance the following string
o’lunney’S bar and grill is across from mcdonald
is correctly formatted as
O’Lunney’s Bar And Grill Is Across From McDonald
For instance the following string
o’lunney’S bar and grill is across from mcdonald
is correctly formatted as
O’Lunney’s Bar And Grill Is Across From McDonald
/// <summary>
/// Capitalize the first character of all words in the given string
/// </summary>
/// Text to format as string
/// Returns the formatted text
public static string InitCap(string textToformat)
{
string pattern = @"\w+\W+";
string result = "";
Boolean capitalizeNext = true;
foreach (Match m in Regex.Matches(textToformat, pattern))
{
// get the matched string
string x = m.ToString().ToLower();
// if the first char is lower case
if (char.IsLower(x[0]) && capitalizeNext)
{
// capitalize it
x = char.ToUpper(x[0]) + x.Substring(1, x.Length - 1);
}
// Check if the word starts with Mc
if (x.Length > 3 && (x[0] == 'M' && x[1] == 'c' && !String.IsNullOrEmpty(x[2].ToString())))
{
// Capitalize the letter after Mc
x = "Mc" + char.ToUpper(x[2]) + x.Substring(3, x.Length - 3);
}
if (capitalizeNext == false)
capitalizeNext = true;
// if the apostrophe is at the end i.e. Andrew's
// then do not capitalize the next letter
if (x[0].ToString() == "'" && m.NextMatch().ToString().Length == 1)
{
capitalizeNext = false;
}
// collect all text
result += x;
}
return result;
}
Tuesday, February 24, 2009
Windows 7
Ive been running windows 7 in a virtual machine (Microsoft VM SP1) on my IBM Thinkpad for the past couple of weeks. The virtual hard disk is on an external 7200 RPM Western Digital My Book drive that is connected to a USB 2 hub. The host operating system is Win XP SP3. The VM is set to use 1gb of the host OS's memory instead of the default 512 kb and is set to access a shared folder on the host and also the host machine's wireless and wired network adapters.
The first thing I noticed about windows 7 is that compared to Vista, Win7 is lightning fast!
I still don't care for the UAC prompts, they are just as intrusive and annoying as they were in vista. Other than that I love the clean no nonsense interface. I love the fact that they got rid of the side bar that was in vista. The operating system its self seems quite stable, In fact given that it is still in a beta stage, I expected to have lots of problems setting it up in a VM environment, including problems accessing the shared folders and devices on the host system. I was pleasantly surprised when it installed smoothly and had no issues what so ever accessing drives or devices including the network adapters. As a matter of fact I haven't had it crash or blue screen even once in the past 2 weeks that I have been using it! Windows 7 comes with the beta version of IE8 and after the initial set up I was able to install and use all of the regular plugins such adobe flash, windows media player, Quicktime etc.
My next test is to start doing some development on it and test drive visual studio and few other dev tools on it. For those who are interested here is a link to the Windows 7 developer Guide
http://msdn.microsoft.com/en-us/windows/dd206698.aspx
Cheers!
The first thing I noticed about windows 7 is that compared to Vista, Win7 is lightning fast!
I still don't care for the UAC prompts, they are just as intrusive and annoying as they were in vista. Other than that I love the clean no nonsense interface. I love the fact that they got rid of the side bar that was in vista. The operating system its self seems quite stable, In fact given that it is still in a beta stage, I expected to have lots of problems setting it up in a VM environment, including problems accessing the shared folders and devices on the host system. I was pleasantly surprised when it installed smoothly and had no issues what so ever accessing drives or devices including the network adapters. As a matter of fact I haven't had it crash or blue screen even once in the past 2 weeks that I have been using it! Windows 7 comes with the beta version of IE8 and after the initial set up I was able to install and use all of the regular plugins such adobe flash, windows media player, Quicktime etc.
My next test is to start doing some development on it and test drive visual studio and few other dev tools on it. For those who are interested here is a link to the Windows 7 developer Guide
http://msdn.microsoft.com/en-us/windows/dd206698.aspx
Cheers!
Monday, February 2, 2009
Microsoft Business Rules Framework
Came across this fantasitc article by Rick Garibay on programming with the Microsoft Business Rules Framework that has made this somewhat exotic techonology (for me atleast) more hands on.
Thursday, December 18, 2008
PowerCommands for Visual Studio 2008
I recently came across an article on Dev Source about Power commands for visual studio 2008 and was intrigued to see what was in this bag of tricks. The article written by John Mueller is an excellent introduction and I found it to be a much better introduction to the toolkit than the documention itself.
PowerCommands definitely helps you get more from Visual Studio by extending the functionality that Visual Studio provides. If you are an ardent user of ReSharper like me I found that it did add a lot of functiontions that just arent available with ReSharper such as the function to copy a project as a as project reference, Edit a project file etc. Some functionality on the other hand is duplicated like the ablity to sort and remove unused using statements (CleanUp code in ReSharper)
Overall I like the tool kit and it is proving to be quite a time saver. It does tend to make your context menus fairly long though if you also have Resharper.
You can Download PowerCommands for Visual Studio 2008 here.
PowerCommands definitely helps you get more from Visual Studio by extending the functionality that Visual Studio provides. If you are an ardent user of ReSharper like me I found that it did add a lot of functiontions that just arent available with ReSharper such as the function to copy a project as a as project reference, Edit a project file etc. Some functionality on the other hand is duplicated like the ablity to sort and remove unused using statements (CleanUp code in ReSharper)
Overall I like the tool kit and it is proving to be quite a time saver. It does tend to make your context menus fairly long though if you also have Resharper.
You can Download PowerCommands for Visual Studio 2008 here.
Thursday, November 20, 2008
Monday, June 2, 2008
2012: The Year The Internet Ends
How the industry will kill the Internet in about 4 years from now.
http://ipower.ning.com/netneutrality
A friend sent me a link to this. A lot of what is said there is pretty far fetched however I must admit even the thought of an ISP adopting a cable provider's business model to provide access to the internet is scary. Can you imagine an ISP saying you can access 200 more sites for $39 a month :)
For those of us in the US and the western world having unlimited internet access is almost a given, and choosing ISPs over who provides the highest speed and features such as a fixed IP, phone, TV, etc is taken for granted .
You may find it interesting that on the other side of the world in India for instance access to the internet is limited for the average home user, not by the number of websites you visit but but the amount of bandwidth you are allowed to consume! usually this is to about 256 mb per month! So though this does not go as far as saying what sites you can and cannot access it does limit your access to a lot of rich content.
In all fairness though these limitations are due to the limited bandwidth and infrastructure that is available. Can you imagine the chaos it would cause if ISPs here started doing that?
I shudder at the thought.
read more digg story
http://ipower.ning.com/netneutrality
A friend sent me a link to this. A lot of what is said there is pretty far fetched however I must admit even the thought of an ISP adopting a cable provider's business model to provide access to the internet is scary. Can you imagine an ISP saying you can access 200 more sites for $39 a month :)
For those of us in the US and the western world having unlimited internet access is almost a given, and choosing ISPs over who provides the highest speed and features such as a fixed IP, phone, TV, etc is taken for granted .
You may find it interesting that on the other side of the world in India for instance access to the internet is limited for the average home user, not by the number of websites you visit but but the amount of bandwidth you are allowed to consume! usually this is to about 256 mb per month! So though this does not go as far as saying what sites you can and cannot access it does limit your access to a lot of rich content.
In all fairness though these limitations are due to the limited bandwidth and infrastructure that is available. Can you imagine the chaos it would cause if ISPs here started doing that?
I shudder at the thought.
read more digg story
Wednesday, February 7, 2007
Doing Objects in Visual Basic 2005
Deborah Kurata's new book is out on safari (http://safari.informit.com/) before it is released to the stores on the 28th of Feb 2007. I couldn't find the the sample code for the book on safari's website and the book directs you to http://www.insteptech.com/ ,which, I think is a poorly constructed site cobbled together on frontpage. Anyhow, the sample code isn't there and whats more there is no mention of the book either. Weired.
The book The Addison-Wesley Microsoft Technology Series Doing Objects in Visual Basic 2005
itself is a great intro to object oriented development in Vb 2005 and the whole concept of binding controls to objects is just fantastic. The book examines this topic in depth and also details various pros and cons of binding different controls.
Im still reading the book but the material presented in it so far has been so good I cant wait to put the stuff I learn in to practice.
The book The Addison-Wesley Microsoft Technology Series Doing Objects in Visual Basic 2005
itself is a great intro to object oriented development in Vb 2005 and the whole concept of binding controls to objects is just fantastic. The book examines this topic in depth and also details various pros and cons of binding different controls.
Im still reading the book but the material presented in it so far has been so good I cant wait to put the stuff I learn in to practice.
Subscribe to:
Posts (Atom)