Blog ( Of Ryan Olshan)

Recent Posts

News

About Ryan Olshan

LinkedIn Profile

Follow Ryan via twitter

Join StrongTypes - Free Generics Help By Email
Join StrongTypes

Community Credit Winner

View my MVP profile

The posts on this weblog are provided "as is" with no warranties and confer no rights. The opinions expressed herin are my own personal opinions and do not represent my employer's view in any way.

Subscribe to Rolog via My AOL
Subscribe to Rolog via Bloglines


Subscribe to Rolog via Feedburner

Furl Rolog




Subscribe to Rolog via Newsburst


Subscribe to Rolog via Pluck

Add Rolog to Technorati Favorites




Thycotic Secret Server

Receive Email Updates


.NET Websites

  • => StrongTypes.com <=
  • Community Credit
  • DotNetCharity.com
  • DotNetSlackers
  • EasyListBox
  • LearnAsp.com
  • SystemNetMail.com
  • SystemWebMail.com

Blogroll

  • Alex Campbell
  • Carlos Magalhaes
  • Charles Carroll
  • Chris Taylor
  • Darren Neimke
  • David Betz
  • Eric Smith
  • Rob Caron
  • Rob Howard
  • Sam Gentile
  • Scott Guthrie
  • Scott Mitchell
  • Tess
  • Wesner Moise
  • Jason Alexander
  • Bill Ryan
  • Steve Smith
  • Sahil Malik
  • David Silverlight

Other Websites

  • 911 Pigeon Alert
  • Pacific Wildlife Project

Strong Coder Bloggers

  • Dean Fiala
  • Doug Nelson
  • Kevin Jones

Yahoo! Groups

  • => StrongTypes <=
  • AspNet2
  • AspNet20GridView
  • PayPalDevDotNet
  • RubyOnRails
  • VSTS

Tuesday, December 20, 2005 - Posts

Random Thought of the Day - Apartment Threaded Components

If threaded components can reside in apartments, then where do the wealthy threaded components live? Mansions?

Share this post: | bookmark it! | digg it! | reddit! | kick it! | live it!
Posted: Dec 20 2005, 08:49 PM by Ryan Olshan | with 1 comment(s)
Filed under:
MagicAjax - Easy as 1, 2, 3

A couple of days ago I discovered MagicAjax. MagicAjax simplifies creating Ajax enriched content. So, how do you use MagicAjax?

Click here to download MagicAjax.

Step 1  Add a reference to the MagicAjax assembly to your project or a copy of it to the bin directory if you are not using an IDE. Also, add the following HTTP module reference to Web.config:

< system.web >
    < httpModules >
       < add name = " MagicAjax " type = " MagicAjax.MagicAjaxModule, MagicAjax " />
    httpModules >
system.web >

Step 2 Add the following to top of the web form you would like to use MagicAjax on:

<% @ Register TagPrefix ="ajax" Namespace ="MagicAjax.UI.Controls" Assembly ="MagicAjax" %>

Step 3 Use the AjaxPanel control as a place holder for content that you would like to enable Ajax on.

< ajax : AjaxPanel ID ="AjaxPanel1" runat ="server">
   [Content here]
ajax : AjaxPanel >

There you have it. It's as easy as 1, 2, 3.

Share this post: | bookmark it! | digg it! | reddit! | kick it! | live it!
Posted: Dec 20 2005, 03:39 PM by Ryan Olshan | with 4 comment(s)
Filed under: ,
What sets C++ Templates and .NET Generics apart?

C++ Templates and .NET Generics are not the same. There are many differences between them, but the biggest thing that sets them apart is that C++ Templates are instantiated at compile-time while Generics are instantiated at run-time.

Since C++ Templates are instantiated at compile-time, a copy of the code for each instance is generated, replacing the type placeholders with the actual data type. It is the equivalent of creating separate methods that handle several data types. In other words, declaring List, List, List, and List will cause the compiler to generate code for each declaration. Even though there are two Lists of integers, the compiler will still generate the code for both Lists. This seems repetitive, but pretty harmless on the surface. However, what if you have two assemblies where List in Assembly1 is dependent on List in Assembly2, but List in Assembly2 is seen as a completely different type then List in Assembly1? This presents a problem as it is like attempting to return a long or another data type other than an integer.

On the other hand, since Generics are instantiated at run-time, generic specializations are created on demand and share the underlying code whenever possible. This resolves the problem present in C++ Templates as mentioned above.

Share this post: | bookmark it! | digg it! | reddit! | kick it! | live it!
Posted: Dec 20 2005, 01:31 PM by Ryan Olshan | with no comments
Filed under:
More Posts