Archive by Author

IIS7 and Classic ASP – Enabling Error Messages

Recently iv switched a lot of my web apps from an IIS6 to an IIS7 server although this came with a few headaches, one of which was that now, I was unable to debug my code from the browser on my remote machine, instead just seeing an “Error Code 500 – Internal Server Error” message,  which is basically useless.

Iv found the solution, although it involves a few steps,  heres how.

  1. In your IIS7 control panel, under your site home area, double click on the “ASP” icon (In the bottom half, on my window).
    Expand the Debugging Properties toggle , and switch the Send Errors To Browser option to TRUE.
  2. Open up a command line and run this command:
    %windir%\system32\inetsrv\appcmd.exe set config -section:system.webServer/httpErrors -errorMode:Detailed
  3. If your using Internet Explorer, go into  Tools > Internet Options > Advanced , find the “Show friendly HTTP error messages” under the “Browsing” section and disable it.
  4. Thats it!  Your done.

Canon DSLR Range Basic Overview

Canon DSLR cameras come in 3 different target groups, which results in 3 different price brackets. 5DII Ill attempt to summarize as simply as possible what these groups are and hopefully clear up any confusions you may have with the Model numbering.

Continue reading “Canon DSLR Range Basic Overview” »

FireFox NTLM Authentication – Windows Authentication

Maybe its just me, but having to switch between Internet Explorer and Firefox to access Internal and External sites is a hassle.  Particularly the SharePoint based sites on Firefox.

So iv found a solution ..  If you want to use FireFox for all sites heres what I did to get it working.

In FireFox

Enable auto NTLM authentication for the internal sites that require domain accounts.

  1. Open FireFox and type about:config hit enter
  2. In the filter box type NTLM , find the key -  network.automatic-ntlm-auth.trusted-uris
  3. Add a comma separated string of URLS here .. Example http://intranet,http://somelocalsite,http://sharepoint
  4. Restart firefox

When you visit these sites now, you will be authentication in the same way you are with Internet Explorer without being prompted to login.  This is absorbed from your domain account.

T-SQL Copy Table To Another Database

Occasionally, you might do something stupid like run a SQL script on the wrong database, or setup your application to configure its table structure on the master DB.

When you do, here’s an easy way to copy the tables to another database (on the same server)

1
2
SELECT * INTO target_db.target_table_name
FROM source_db.source_table_name

Dear FireFox, Call Me When You’re Sober

Dear FireFox,

I wish I could say this to you in person although I fear that I may not be able to go through with it.

You’ve been my rock for so many years and you held my hand while I was weaning off Internet Explorer, and I thank you for that, but you’ve changed.

Continue reading “Dear FireFox, Call Me When You’re Sober” »

Register ASP.NET Version In IIS

If your IIS Web Service Extensions list is not showing your correct version of ASP.NET, ie It may only show version 1.1.3822 where as your using version 2 in your application, click start > run and then enter this command , replacing the .NET Framework version with your desired version.

1
C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\aspnet_regiis.exe -I

Windows 2008 Perfmon Crashes – Reset User Defined Data Collector Sets

I discovered this very annoying bug in Windows Server 2008 when attempting to import an XML file with 100 serverswind2008 and counters in it.
No doubt one of the server had an issue and therefore and for some stupid reason, perfmon or Reliability And Performance Monitor, as its called now in 2008 is unable to handle this , and completely falls over.
Now, when you open Perfmon and try to view the User Defined Data Collector Sets, or run logman.exe from the command line, the application completely freezes and your unable to delete the corrupt dataset you just imported or even click elsewhere in the window.

In 2003, a reboot would fix this problem, but in 2008 it does not. The solution lies in the registry. Here’s how to fix the problem.

  1. Make sure your logged in as admin or with admin rights
  2. Close any open perfmon (Reliability and Performance Monitor) windows you have open.
  3. Click Start > Run then type  regedit hit enter
  4. Goto: HKLM\Software\Microsoft\Windows NT\CurrentVersion\Schedule\TaskCache\Tree\Windows\PLA
  5. You will see your Data Collector Sets in here, delete the one you created that caused the problem (or just delete them all if your not sure) **NOTE** Dont delete the “System” folder.
  6. Your done now, re-open perfmon, or logman and your problem should be solved.

SQL Replace Nulls With Blank String

Simple way to replace NULL values in your queries with blank strings by using the IsNull function.

This will allow for problem free string creation etc.

1
2
3
SELECT IsNull(ColumnName, '') 
As NewColumnName 
FROM TableName

More information can be found here: http://msdn.microsoft.com/en-us/library/ms184325.aspx

VBScript To Pull Events From Event Log And Email To Yourself – Past 24 Hours

So, you want to see what events have occured on a server in the past 24 hours. Maybe you have a problematic server, throwing errors but your event log is so massive , its hard to sort through.

This script will sift through your entire event log, searching for any events in the past 24 hours that match your event code, it will save the results to a .TXT file , and then email them to you. v.handy

Continue reading “VBScript To Pull Events From Event Log And Email To Yourself – Past 24 Hours” »

VB.Net Forms Confirmation Box

How to create a simple confirmation box in a VB.Net WinForms application.    This will pop up a typical “Do You Wish To Continue ? ” Box , to which each button has a different action.

Continue reading “VB.Net Forms Confirmation Box” »

Kill All Processes Of Certain Application In Unix/Linux

This is a very helpful command I use regularly.

If your like me, you open several instances of applications like “VI” and leave them in the background, most of the time without meaning to.  Eventually you run a “PS -U” to view all your processes running and realize that theres 10 copies of the application running in the background which you havnt closed. Heres a command to quickly clear that up. Continue reading “Kill All Processes Of Certain Application In Unix/Linux” »

SteerMouse For Mac OSX

Hardest part about moving to a mac was Apples terrible mouse acceleration system and its highly in-accurate  USB rate … It basically made it impossible to do the graphic design work that I used to do on a PC.   Anybody coming from a PC to a mac that does any sort of accurate mouse work will know what im talking about . . . Steermouse fixes that problem and gets your mouse running smooth as silk  .. I highly recommend it ! http://plentycom.jp/en/steermouse/

Embedding XHTML Compliant Flash Files

All to often people all over the web use non-xhtml embedding on their sites.
Use the following code to embed fully XHTML 1.0 compliant flash objects. Continue reading “Embedding XHTML Compliant Flash Files” »

Importing VBS Files In Your VBScript Project

If you have certain functions you use over and over , why not compile them all into a single library file , and simply “Import” them into your new projects, like a real object oriented language does?.

If your one of those people that has a script to do everything , you may find the need to organise your functions and files necessary. You can use this method to store configuration options too.

Here’s how.

Continue reading “Importing VBS Files In Your VBScript Project” »

How To Convert Custom Date Format In VB.Net

Problem:

I want to convert my custom 12 hour date and time string into a proper 24 hour DateTime format. Continue reading “How To Convert Custom Date Format In VB.Net” »

Help Me eMailbomb An eBay Scammer

So we’ve all seen it, but it still burns me up everytime.  You try to sell something on eBay,  you get creative with photoshop and attempt to make it all look pretty,  you list the thing for 9 days or so to get your money’s worth , and then you sit there each day watching the auction eagerly like an old man in a peep show. Continue reading “Help Me eMailbomb An eBay Scammer” »

Sorry!

We’ve had an overhaul and many of the older articles have new URL’s. Please check the various categories for the one your after,

Gazeek.com blogging

So gazeek is now a blog based site.

If you’de like your own blog section, drop me a line.

Cheers

How To Conceal Your Pr0n In a JPG

So your sick of your Girlfriend / Mum / Dad / Brother / Gay mates stumbling across your pr0n right ?  Here’s a little tip that will help solve that problem for good. Continue reading “How To Conceal Your Pr0n In a JPG” »

Introduction To Powershell (Move Over Bash)

For years UNIX/Linux administrators have looked down on the windows environment,one of the main reasons being that windows did not have a nice CLI. UNIX has always had sh, bash, ksh which are great shells. Microsoft has now introduced Windows PowerShell (Codename MONAD) a very powerful .NET based shell. A shell is a great tool for system administrators to automate tasks. Continue reading “Introduction To Powershell (Move Over Bash)” »