Latest Entries
ASP.NET and Ajax - using XmlHttpRequest
calendar_today 08 May 2007 17:32
If you are not interested in using the ASP.NET AJAX library offered for ASP.NET, but would like to feature small amounts of AJAX functionality on your pages, you can do this easily with some javascript and a receptive page.
AJAX and Classic ASP
calendar_today 06 May 2007 23:29
Using the xmlhttpserver object in javascript to request an asp page containing script to output text.
Analyse the tables and saved queries in an Access database with ADOX
calendar_today 06 May 2007 22:34
The following code will enumerate the tables and their properties, together with the queries in an Access database. Saved SELECT queries are referenced using the Views collection, and INSERT, UPDATE and DELETE queries are referenced from the Procedures collection.
How to highlight a GridView's row on hover
calendar_today 06 May 2007 20:50
As the user hovers over each row, it becomes highlighted, with the help of a small amount of javascript.
How to make an ASP.NET Table row highlight and become clickable
calendar_today 06 May 2007 20:38
For those people who like to output their data to an asp:Table, highlighting the entire row and making it clickable can make it obvious to the user that some action is expected from them. This emulates the behaviour that can be found in some desktop applications. All that's needed for this is a bit of javascript, and the use of AddAttributes() for the table rows.
How to center the content of a web page
calendar_today 05 May 2007 20:48
This question gets asked very often in the forums and newsgroups, and is very easy once you know how.
How to force a scrollbar for centered web pages
calendar_today 05 May 2007 20:45
If you have centered web pages, there can be times where the depth of content doesn't reach the bottom of the window browser, so no scroll bar appears. Navigating between long and short pages can give the appearance of the centered content "jumping" from side to side.
Include contents of an html page in an aspx page
calendar_today 05 May 2007 20:44
If you are creating a new ASP.NET application, but have a huge collection of existing content in html files, one option is to move all the content into a database and generate pages dynamically. However, migration to a database can be a time-consuming task depending on the volume of content. So wouldn't it be easier to somehow import the relevant parts of the existing html pages into your aspx page?
Javascript 24 hour clock
calendar_today 01 May 2007 22:54
A snippet for a javascript clock showing time in 24 hours with seconds
Getting various bits of URL with C#
calendar_today 27 April 2007 21:49
Need some bit or all of the URL for any reason?
Parameter Queries in ASP.NET with MS Access
calendar_today 13 April 2007 22:17
A selection of code samples for executing queries against MS Access using parameters.
Paging long articles in ASP.NET using C#
calendar_today 09 April 2007 21:44
Long articles are better broken into bite-sized chunks over several pages. With static HTML, this is easily achieved by dividing the article into logical separations and creating separate .htm files for each. Here's how to do it using C# for an article that gets posted to a database.
Regular Expressions and VBScript
calendar_today 09 April 2007 12:42
Regular Expressions provide a much more powerful and efficient way of manipulating strings of text than the use of a variety of standard string functions. They have a reputation of being cryptic and difficult to learn, but are actually quite easy to learn and use.
Date Formatting in C#
calendar_today 08 April 2007 21:11
Cheat sheet detailing formatting options for dates and times in C#.
Date formatting in VBScript
calendar_today 08 April 2007 20:22
A cheat sheet for people who want to format dates using VBScript
Migrating from Classic ASP to ASP.NET - equivalent objects and classes
calendar_today 07 April 2007 10:01
Having spent some time familiarising oneself with the objects available in Classic ASP, it can be tricky sometimes to find the .NET framework equivalent. Here's a guide.
How to retain carriage returns or line breaks in an ASP.NET web page
calendar_today 06 April 2007 19:55
Many newcomers to web development cannot get their head around why the carriage returns they made in their data on input from a textarea, or from a text file, Excel spreadsheet etc. do not appear when the web page renders.
Create an RSS Feed In ASP.NET 2.0 C#
calendar_today 05 April 2007 22:37
Using the XmlTextWrite to output an XML file that serves as an RSS feed.
How to conditionally show an image, or other control in ASP.NET
calendar_today 04 April 2007 21:45
Quite often, you want to display an item from a database that may or may not have an associated image. Examples might include a news story, product details, car for sale etc. But you want to avoid the dreaded "redex" if a picture isn't present.
Create A Utility Class Containing Site-Wide Functions
calendar_today 03 April 2007 21:33
In Classic ASP, the typical model for managing site-wide functions is to create one or more server-side includes containing libraries of code. The OOP nature of ASP.NET offers a much more elegant solution.