Posts

Showing posts from 2011

Designing Software with Generics and Reflection in C# ASP .NET

Introduction As software becomes more complex, the ability to design a modular and re-usable architecture into your software becomes increasingly important. Using the programming concept of generics with interfaces, included in C# ASP .NET 2.0, software developers can abstract algorithms and classes into individual class libraries. The libraries can be accessed, in a generic fashion, from the main software. The key to this process relies on using interface design patterns and .NET reflection. What's a Generic? .NET generics can cover several related topics. The common usage of generics is specifying templated object names instead of concrete ones, which lets you pass multiple types to a function rather than only the concrete form. However, in the example listed below, we will be focusing on using generics and reflection with a class library interface architecture. This is becoming a popular method of programming enterprise software, as it provides a great deal of re-usable modules

What are 5 common problems in the software development process?

Problems •Poor requirements - if the requirements are not clear, unfinished, too common, and not testable, then there will be problems. •Unrealistic schedule - if too much work is given in too little time, problems are inevitable. •Inadequate testing - no one will know whether or not the program is any good until the customer complain or systems collide. •Futurities - requests to pile on new features after development is underway; extremely common. •Miscommunication - if developers do not know what's needed or customer's have wrong expectations, problems are assured. Solutions •Solid requirements - clear, complete, detailed, cohesive, attainable, testable requirements that are agreed to by all players. Use prototypes to help nail down requirements. In 'agile'-type environments, continuous close coordination with customers/end-users is necessary. •Realistic schedules - allow adequate time for planning, design, testing, bug fixing, re-testing, changes, and documentation;

Note Book

Coalesce example : DECLARE @name VARCHAR(1024) SELECT @name=COALESCE (@name + ',', '')+name FROM test select @name delete duplicate records: DELETE FROM MyTable WHERE ID NOT IN ( SELECT MAX ( ID ) FROM MyTable GROUP BY Duplicatev alueColumn1 , DuplicateValueCol umn2 , DuplicateValue Column2 )

When to use Anonymous delegates

When to use Anonymous delegates Best needs: predicates / comparer Hi Ever wondered why anonymous delegates were created when we already had proper delegates? In normal delegate, we write as follows Public delegate MyDelegate (string s); Public void MyFunction(string s) { Console.Write(s); } Public static void main() { MyDelegate del = new MyDelegate(MyFunction); del("Nitin"); } In Anonymous delegates, we write Public static void main() { MyDelegate del = delegate(string s) { Console.Write(s); } del("Nitin"); } Basically this is same as String s = "Nitin"; // this happens in normal delegate myFunction(s); myFunction("Nitin"); // this happens in anonymous delegate Now the difference If we don't need to use the function outside of the delegate scope, we can safely use anonymous delegate and remove the explici

Bookmark

Good Blog about Architecture & design Patterns:   http://martinfowler.com/bliki/ http://www.sharepoint-videos.com/ http://go.cloudshare.com/Linkedin_ProPlus_SharePoint.html A Technical Q/A site: http://www.bookmarkresource.com http://blog.krisvandermast.­ com/ASPNET20PageLifeCycle.aspx http://blogs.vertigosoftware.­ com/shannonf/archive/2005/08/­ 07/1355.aspx http://john-sheehan.com/blog/­ net-cheat-sheets/ http://www.eggheadcafe.com/­ articles/20051227.asp http://duartes.org/gustavo/­ articles/Asp.net-Runtime-­ Cheat-Sheet-HttpRequest-­ HttpRuntime.aspx http://www.addedbytes.com/­ cheat-sheets/javascript-cheat- ­sheet/ http://www.antsmagazine.com/­ 2009/04/100-useful-cheat-­ sheets-for-web-designers-­ developers/ Nice link abt .Net 3.5: http://www.simple-talk.com/ dotnet/.net-framework/.net-3. 5-language-enhancements/ nice articles about JQuery. http://encosia.com/2008/05/29/ using-jquery-to-directly-call- aspnet-ajax-page-methods/ http://encosia.co