Geeks With Blogs

Tim Huffam Dotting the I and crossing the T of I.T. Half Baked Half-baked solutions for our half-baked planet.
How to change permissions on Vista Home so you can update your hosts file
Windows Vista Home edition has some funny quirks - and this one is a prime example... When trying to update my hosts file I get permission denied. That's odd - so I check the permissions and sure enough Administrator group has write access - yet I am the only administror on the system. How's that for tricky - so I'm an admin with no admin rights - go figure. Then I tried deleting the file then readding it.... wow - delete worked but could not re-add. It appears the only way around this little gem ......

Posted On Sunday, February 1, 2009 9:38 PM

Script to remove unchanged files in TFS/VS2008
TFS has a wonderful feature whereby it marks files as changed, even though there are no changes. These files show up in the Pending Changes window in Visual Studio (VS 2008). To work around this, add the following external command to your VS tools: First you need to install TFS Power Tools In VS go into Tools - External Tools and click Add Enter the following details: Title: Unchange Command: C:\Program Files\Microsoft Team Foundation Server 2008 Power Tools\tfpt.exe Arguments: uu /recursive /noget ......

Posted On Thursday, January 22, 2009 3:31 PM

ASP.NET 3.5 controls not being rendered
For some reason some controls/tags within ASP.NET do not always get rendered/passed to the client. This has happened to me on a number of occasions. It seems limited to <style> and <script> tags - but happens for both raw HTML (within the aspx designer) and dynamically created tags (eg using new HtmlGenericControl("style")... This is happening to controls/tags within AJAX updatepanels within, webforms and usercontrols. Sometimes I can work around this by simply placing these controls/tags ......

Posted On Wednesday, July 9, 2008 10:50 PM

Cannot select images in Microsoft Word?
For some reason, sometimes you cannot select images within a Microsoft Word document. This has baffled me on an off for some time - and I still do not know the reason why it behaves like this. Today I stumbled across a very simple (and maybe obvious to some) solution... right-click on the image (instead of trying to left-click to select it). This causes the image to be selected and pop's up the context (right-click) menu. Just press the Esc (escape) key to close the context menu, and the image remains ......

Posted On Thursday, August 30, 2007 4:42 AM

Manually writing to the same windows event log as log4net
This is something I wanted to do as a quick work around (rather than writing my own log4net appender) to being able to write SuccessAudit and FailureAudit events to the event log (something which log4net does not support out the box). Here's the method I used: private static ILog _Log = LogManager.GetLogger(Method... static log4net.Appender.EventLogAp... _eventLogAppender = null; // This only works if you have an EventLogAppender configured.public static ......

Posted On Thursday, December 7, 2006 2:47 PM

SQL Server datetime set blank or null = SQL Server error: System.Data.SqlTypes.SqlTypeException: SqlDateTime overflow. Must be between 1/1/1753 12:00:00 AM and 12/31/9999 11:59:59 PM.
This error (System.Data.SqlTypes.SqlTy... SqlDateTime overflow. Must be between 1/1/1753 12:00:00 AM and 12/31/9999 11:59:59 PM.) will occur if you try to pass an uninitialised DateTime value into an SQL Server stored procedure from .NET code (in my case C# in an ASP.NET app). To work around this you must pass in a value - null will not work. In my case I have a generated class that passes a System.DateTime variable into the System.Data.SqlClient.SqlCo... method. So my ......

Posted On Wednesday, November 8, 2006 8:32 PM

Uninstall IE 7
Those of you wanting to know how to remove this annoying version on IE - click here. However, if you are as unfortunate as myself, and have had another user has install it (IE 7 beta) on your PC, then you will get this error: "Internet Explorer 7 Beta 1 cannot be uninstalled from this user account. Please log on to the same user account from which it was installed and try again." Even if you belong to the local administrators group. Brilliant! *** Update: For those of you wanting a far superior browser ......

Posted On Friday, September 16, 2005 12:14 PM

Copyright © Tim Huffam | Powered by: