Today we will learn how to instantiate a generic class and execute a generic method without knowing what class type to use when instantiating the generic (i.e. new GenericClass<DynamicParameterType>();
).
(more…)
January 3, 2015
Executing Generics with Dynamic Parameter Types
July 26, 2014
June 28, 2014
Big Brother, Little Brother or No Bother?
Ever see the message, “Your IP Address has been recorded?” In this article we will review what kind of information a web site can gather about you, why a web site may need this information and how to get the information using c#.
(more…)
Web Information
An ASP.Net Page provides simple, convenient access to HTTP Context data like Request, Response, Server, QueryString and Cookies to name a few. While re-factoring code to improve reuse often I find a need to move code from the web page and into a reusable class. (more…)
March 25, 2011
C# IsNumeric Function
I have been a Visual Basic programmer for the last ten years. I truly enjoy writing in this language. However, I also write software in C#. One of the things I have noticed that is missing from C# is a simple routine that tells me if a value is a number. Of course I could reference the Microsoft.VisualBasic namespace. Since I don’t want to be ostracized by the C# community I created a C# IsNumeric function using a regular expression instead.
March 9, 2011
Argument Validation
I wanted to take a small break from the Active Directory Data Access Layer to discuss a best practice that should be considered when constructing a code library. The first priority when constructing a reusable code base is the class diagram. The structure of the classes and the names of the methods impact how easily a class library can be to implement. Equally important is the careful attention to detail for argument values.