See Joel Program

August 19, 2008

.NET 3.5 SP1 Doesn’t Provide Composite Script Registration from an IScriptControl (out-of-the-box)

Filed under: AJAX, ASP.NET AJAX — Joel Rumerman @ 9:43 pm

Note: Below the following little story, there’s a work around that I came up with so if you’re looking for help, jump down a bit.

The Story

A story of despair. Here’s how my evening went.

Act I Scene I: I just downloaded and installed the Visual Studio 2008 SP1 / 3.5 SP1 and I’m excited to take a look at how to use the Script Combining mechanism. I’ve been using the ToolScriptManager’s script combining ability for a while now, and while it is okay, it has its quirks and I was hoping the one in .NET 3.5 SP1 would be better.

Act I Scene II: I notice that the ScriptManager has a new templated section called CompositeScript. This is the spot I need to investigate closer.



August 7, 2008

Supported Number and DateTime Format Strings in ASP.NET AJAX

Filed under: ASP.NET AJAX — Joel Rumerman @ 11:41 am
We all make mistakes, some are just published in books.

Consider this my first correction to Adam’s and my book: Advanced ASP.NET AJAX Server Controls for .NET 3.5.

In Chapter 6: ASP.NET AJAX Localization, on page 289, we have a tip on Data Format Strings. It states that “the data format strings available for the Date and Number types in JavaScript are the same as those that are available in .NET for the DateTime and Double types.” This is incorrect.
The format strings that are allowed for Number types are the following:

  • c or C: Currency
  • p or P: Percentage
  • d or D“: Decimal (# number of digits)
  • n or N“: Numeric (# number of digits after decimal)

– e, f, g, r, x, and custom format strings are not supported

The standard format strings that are allowed for the Date type are the following:
  • d: Short date pattern
  • D: Long date pattern
  • t: Short time pattern
  • T: Long time pattern
  • F: Full date/time pattern (long time)
  • m or M: Month day pattern
  • s: Sortable date/time pattern
  • y or Y: Year month pattern
– the standard format strings: f, F, g, G, O, o, R, r, u, U are not supported. However, custom format strings that use the “mmm”, “yyyy”, “hh”, etc. formats are supported. You can build your own date format string.

Create a free website or blog at