Geeks With Blogs

Tim Huffam Dotting the I and crossing the T of I.T. May 2006 Entries
ASP.NET 2.0 error: Unable to start debugging on the web server.
The following error may occur when trying to run/debug an ASP.NET 2.0 web app, when the web server is not configured properly: "Unable to start debugging on the web server. The web server is not configured correctly. See help for common configuration errors. Running the web page outside of the debugger may provide further information." This is usually caused because of one or both of the following problems: The directory the web app resides in has not been registered as a web application. The correct ......

Posted On Monday, May 29, 2006 6:08 PM

Accessing Outlook items from C# .NET
The following demostrates how to retreive data from items within an Outlook folder (called "MySubFolderName" under the Inbox folder) using .NET: First add a reference to the Outlook COM object your project: In VS.NET right click on References and choose Add Reference. Select the COM tab Choose "Microsoft Outlook 11.0 Object Library" (this is for MS Office 2003 - I think 10.0 is for Office XP) and click Select. Click OK. Note that you can access any Outlook/Exchange object types, eg Appointments, ......

Posted On Friday, May 26, 2006 10:35 AM

Atlas web site templates missing from "My Templates" after Atlas installation
If you've just installed ASP.NET Atlas, and have started up VS2005, clicked File - New - Web Site... ..but, hang on... the "Atlas Web Site" template isn't there (as it should be according to the 'Setup your environment' section of the Atlas setup). In my case it appears that the original installation either had a problem (although I don't remember any issues at the time) or some how corrupt the templates or lost reference to them. Well all's not lost. To fix I did the following: Open Windows Explorer ......

Posted On Thursday, May 25, 2006 6:46 PM

How to convert special characters to HTML encoded equivalents using C#.NET
public string HTMLEncodeSpecialChars(string text){ System.Text.StringBuilder sb = new System.Text.StringBuilder(); foreach (char c in text){ if(c>127) // special chars sb.Append(String.Format("&a... else sb.Append(c); } return sb.ToString();} ......

Posted On Thursday, May 25, 2006 12:31 PM

How to get ascii/unicode character codes using C#.NET
For each character in the string this displays: The character It's unicode character code in hex It's unicode character code number string text = "0 a+…”"; foreach (char c in text) { Console.WriteLine("{0} U+{1:x4} {2}", c, (int)c, (int)c); } HTH Tim ......

Posted On Thursday, May 25, 2006 12:28 PM

WordPress install error: Directory Listing Denied
After installing WordPress (WinXP, IIS 5, MySQL 5.0.21, PHP 5.1.4) and going through the install, after logging in for the first time I got the error: "Directory Listing Denied". This was because IIS had not been configured to look for a default document called "index.php". To fix: Go into IIS admin Right click on the root dir where wordpress resides Select the Documents tab Click on Add... Enter index.php and click OK. Then you should just need to refresh your WordPress page in the browser. HTHTim ......

Posted On Wednesday, May 24, 2006 12:23 PM

System.DirectoryServices.DirectorySearcher.Timeout and ServerTimeLimit not working for non AD LDAP directory (GDS)

I've been running several searches against a GDS LDAP directory - and
the Timeout and ServerTimeLimit properties of the DirectorySearcher
class appear to have no effect.

After further testing I've discovered that the problem is caused because I was using sub second timeout periods eg 500ms - and the LDAP server I'm accessing (GDS) only supports timeout periods of whole number seconds.

HTH

Tim

Posted On Friday, May 19, 2006 8:34 AM

Access is denied - Javascript error when attempting to load xml from an external site.
As yet I don't have the answer to this problem - so any suggestions would be very much appreciated! I have a JS library with an object that loads xml from a specified URL and populates specified HTML elements with the data. This works fine. However recently I refactored the code that calls this library, to be more OO (to allow it to be more easily extended). Now the xml "load()" method raises the error "Access is denied" when loading from external urls. I've proved that the load library still works ......

Posted On Wednesday, May 17, 2006 8:13 AM

DOM Inspector not working in FF (FireFox)
When you install Firefox on windows, by default it does not install the DOM Inspector. To make sure it installs it, select Custom Install then select Web Developer Tools. If you already have FF installed you can install the DOM Inspector without having to reinstall FF: Run the FF installer - just so it unpacks the install without installing anything. Use file explorer to locate the C:\Documents and Settings\<username>\L... Settings\Temp dir. FF will have created a temp directory to unpacked ......

Posted On Thursday, May 11, 2006 7:40 PM

How to lookup a user name and machine name using an IP address (on windows)
If you need to find a username but only have an ip address, if you use active directory (AD) then you can use the following method to find out the username: At the command prompt enter the following command:nbtstat –a ipaddressWhere ipaddress is the ip address.This will list the machine name using that ip address. Then run the following command:net view /domain:ad > somefile.txtWhere ad is the name of the domain you want to search and somefile.txt is the name of the file to contain the output. ......

Posted On Wednesday, May 3, 2006 8:30 AM

Problems with NDoc (content not updating/reflecting changes or missing content)
If you are not seeing changes you've made to your xdoc comments, it's possible that NDoc is referring to an old xdoc file. I had this occur when, some time ago, I had set my project's build options to use a XML Documentation File (eg MyAssembly.xml), then at a later state I cleared the setting. When I set up NDoc to point to my assembly (eg MyAssembly.dll) it used the MyAssembly.xml file instead. This caused two problems - firstly it the docs were out of date, and secondly any changes I made subsequently ......

Posted On Tuesday, May 2, 2006 2:06 PM

Copyright © Tim Huffam | Powered by: GeeksWithBlogs.net