Geeks With Blogs
The Quandary Phase This code was generated by a tool. October 2008 Entries
ASP.NET: Alternatives to Dynamic Controls - Part 2
I recently posted a short article on avoiding the use of dynamic controls in ASP.NET; for part 1, please click here. Part 1 demonstrated the basics of using a listview control to dynamically generate a table containing a number of textboxes, allowing the user to select how many textboxes are required at runtime. This is the type of problem that is best solved without the use of dynamic controls, and part 1 explained why this is so. This article will extend the code from part 1, to show how to preserve ......

Posted On Thursday, October 23, 2008 12:39 PM

Using Reflection To Extract Values From a Static Class
An interesting question arose today of how to read property values from the HttpContext class dynamically. It is easy to imagine why this would be useful. For example, you might want to store a number of property names in a configuration file, and retrieve these values on-the-fly, perhaps for logging purposes. The first thing to notice about the HttpContext class is that it manages its own instances. What I mean by this is the class contains a public static property named 'Current' which returns ......

Posted On Wednesday, October 22, 2008 4:57 PM

Oracle: Last Weekday In Month Function
Just a quickie: today I found need for a PL/SQL function to calculate the 'Sale Month' for a given transaction. The organisation in question derives their sale month from the last Friday of the month: anything before the last Friday is in the current calendar month, anything after the last Friday of the month should appear as the following month. So, to get the last Friday of the month, I used the following: 1: create or replace FUNCTION "FN_GET_SALE_MONTH" 2: ( 3: param_dateValue date 4: ) RETURN ......

Posted On Monday, October 20, 2008 4:38 PM

ASP.NET: Alternatives to Dynamic Controls - Part 1
This is part 1 of what I intend to be something of a recurring theme: how to avoid the use of dynamic controls in ASP.NET. Whilst dynamic controls have their uses in a small number of cases, they come with a significant amount of extra baggage. For example: * Dynamic controls need to be created early in the page lifecycle to participate in viewstate * Dynamic controls need to be re-created on each postback, and assigned the same control IDs to maintain viewstate * Extracting values from dynamic controls ......

Posted On Sunday, October 19, 2008 5:59 PM

AJAX Reorder List, Page Scrolling, and IE7 Quirks Mode Problems
Aha! New blog... I think I will start by posting the solution (or, rather, a solution), to a problem which has been troubling me for the best part of a day. To replicate the problem, simply download and run the AJAX Control Toolkit sample website, and navigate to the Reorder List sample page using IE7. You can drag and drop the list items, and all works as expected. Now go to the site's master page, and comment out the HTML DocType declaration at the top of the template markup, and run the ReorderList ......

Posted On Friday, October 17, 2008 5:56 PM

Copyright © Adam Pooler | Powered by: GeeksWithBlogs.net