Thursday, June 26, 2008

The Six Thinking Hats Theory


The Six Thinking Hats technique of Edward de Brono is a model that can be used for exploring different perspectives towards a complex situation or challenge. Seeing things in various ways is often a good idea in strategy formation or complex decision-making processes.

Source:
<http://www.12manage.com/methods_bono_six_thinking_hats.html>

Tuesday, June 24, 2008

Best Practices for Speeding Up Your Web Site

Excellent article about the best practices for speeding up internet web sites, I recommend reading this one, it’s very beneficial.
<http://developer.yahoo.com/performance/rules.html>

Wednesday, June 11, 2008

Microsoft Source Analysis for C#

This tool is known internally within Microsoft as StyleCop, and has been used for many years now to help teams enforce a common set of best practices for layout, readability, maintainability, and documentation of C# source code.

Source Analysis is similar in many ways to Microsoft Code Analysis (specifically FxCop), but there are some important distinctions. FxCop performs its analysis on compiled binaries, while Source Analysis analyzes the source code directly. For this reason, Code Analysis focuses more on the design of the code, while Source Analysis focuses on layout, readability and documentation. Most of that information is stripped away during the compilation process, and thus cannot be analyzed by FxCop.

The ultimate goal of Source Analysis is to allow you to produce elegant, consistent code that your team members and others who view your code will find highly readable. In order to accomplish this, Source Analysis does not allow its rules to be very configurable. Source Analysis takes a one-size-fits-all approach to code style, layout, and readability rules. It is highly likely that you will not agree with all of the rules and may even find some of the rules annoying at first! However, the majority of teams using this tool within Microsoft have found that after a short adjustment period, they came to appreciate the rules enforced by Source Analysis, and even began to find it difficult to read code not written in this style.

Source Analysis comes with a set of default rules analyzers covering approximately 200 best practice rules. These rules are full compatible with the default layout settings in Visual Studio 2005 and Visual Studio 2008.
Specifically, these rules cover the following, in no particular order:
- Layout of elements, statements, expressions, and query clauses
- Placement of curly brackets, parenthesis, square brackets, etc
- Spacing around keywords and operator symbols
- Line spacing
- Placement of method parameters within method declarations or method calls
- Standard ordering of elements within a class
- Formatting of documentation within element headers and file headers
- Naming of elements, fields and variables
- Use of the built-in types
- Use of access modifiers
- Allowed contents of files
- Debugging text

After installation, Source Analysis can be run from within the Visual Studio IDE, and can also be integrated into MSBuild-based command line builds.


Download Source Analysis for C# from here:
http://code.msdn.microsoft.com/sourceanalysis/Release/ProjectReleases.aspx?ReleaseId=1047

Thursday, June 05, 2008

SQL Injection and how to avoid it

The safest way to keep yourself safe from SQL Injection is to always use stored procedures to accept input from user-input variables.

Details on source link:
<http://blogs.msdn.com/tom/archive/2008/05/29/sql-injection-and-how-to-avoid-it.aspx>

Wednesday, June 04, 2008

Visual Studio, .NET Framework Update Coming

I would like to share with you these news sent to me from Directions on Micrososft :
----------------------

By Rob Helm
Posted: May 26, 2008

Visual Studio and the .NET Framework will get significant updates in a service pack planned for late summer 2008. Currently available in beta form, Visual Studio 2008 SP1 updates the developer tools and the underlying .NET Framework 3.5 with new technologies for Web and database development and makes it more practical to distributed thick-client PC applications. The improved Web and data technologies could reduce coding and make applications more testable and maintainable, although the technologies overlap and could get a future shakeout. Also, the SP1 beta is incompatible with previews of other important developer technologies, complicating its testing.


The most important Web and data development technologies in SP1 have already appeared in a Dec. 2007 technology preview called (somewhat inaccurately) the ASP.NET 3.5 Extensions. However, that preview had a few features that are not in this beta release of SP1, and the beta SP1 includes other technologies that weren't in the ASP.NET 3.5 Extensions preview.


ASP.NET Dynamic Data Speeds Web Applications

The Visual Studio 2008 SP1 beta delivers two notable improvements for Web programming:

ASP.NET Dynamic Data. This feature automatically generates Web pages at runtime that can display data in SQL Server database tables and permit users to update those tables. (For an example of such a Web page, see the illustration "ASP.NET Dynamic Data".) This enables developers to quickly develop simple data-driven applications. It could prove particularly useful for relatively simple applications that business units have traditionally built with Microsoft Access, such as a basic asset tracking or contact management application.

AJAX history improvements. SP1 includes minor improvements for AJAX (Asynchronous JavaScript and XML) programming, a technique in which a Web page downloads XML data in the background so that the entire page doesn't have to be refreshed for each user action. AJAX is heavily used in some Microsoft applications (such as the Outlook Web Access client for Exchange) and in recently developed Web applications (such as Google Apps) because it improves Web application responsiveness without requiring installation of application code or a browser plug-in on the client.

The most notable AJAX improvement in SP1 is a mechanism called history points that supports use of the Back and Forward buttons in AJAX applications. AJAX applications typically break the Back and Forward functionality in the Web browser—a user who clicks Back to try to undo an action, for example, will often leave the application completely and lose any unsaved work. With SP1, a developer can code an AJAX application to store its state at various points in the browser's history, enabling users to return to those points with the Back and Forward buttons as they would when navigating conventional Web applications.

What's Missing

The SP1 beta excludes two notable Web development features that were in the Dec. 2007 ASP.NET 3.5 Extensions preview.

Silverlight Media Player control. The SP1 beta lacks the Silverlight Media Player control, which enables developers to embed interactive audio and video content into ASP.NET applications using Silverlight, Microsoft's alternative to Adobe Flash.

MVC framework. SP1 also lacks the ASP.NET Model-View-Controller (MVC) framework, a set of project templates and supporting code for factoring Web applications into components called the model (business logic and data access), view (page display), and controller (user input interpretation). The MVC design pattern, which is also used in the popular Ruby on Rails framework, can simplify component testing and help solve complex maintenance problems, such as maintaining an application that needs separate Web user interfaces for small mobile devices and full-sized PCs.

The MVC framework and the Silverlight Media Player control will probably appear in the production release of SP1, even though they are not in the current beta.


Higher-Level Data Access

SP1 delivers updated versions of two components that build on top of the ADO.NET data access API to simplify application coding and maintenance.


ADO.NET Entity Framework. The Entity Framework is a set of tools and software components for modeling an application's data, and generating and maintaining code for storing the modeled data in external databases. The goal is to create more maintainable, portable data access code.

A developer using the Entity Framework defines a model of the application's data types (called entities) and creates a mapping between the model and the application's databases. For example, a CRM application developer would define a model that includes a customer entity and map that entity to the specific databases, tables, and fields that store customer data. Once a model has been created and mapped, the developer writes only application code that accesses entities defined in the model; the Entity Framework creates and maintains the code that queries and updates the specific database. The resulting application code should be simpler and more resilient to database schema changes, and could also be portable across database platforms (the Entity Framework supports several platforms, including SQL Server, IBM DB2, and Oracle). The downside is that the developer must build and maintain models and mappings and keep them synchronized with the application code. For applications that must work on multiple database platforms (such as many commercial business applications), and applications whose database schemas change frequently or don't match the application's own data well, the Entity Frameworks' benefits could outweigh the modeling and mapping effort.


SP1 also delivers a feature called LINQ to Entities to enable access to data modeled with the Entity Framework. LINQ (Language Integrated Query) is a .NET Framework 3.5 feature that incorporates general-purpose data query and update commands into C#, Visual Basic, and other .NET Framework languages and is intended to simplify data access code and enable static analysis tools (e.g., Visual Studio's IntelliSense command completion feature) to aid data access programming. LINQ to Entities extends LINQ to query and update modeled entities.


LINQ to Entities will also be the only way to use LINQ with non-Microsoft database platforms, such as IBM DB2 and Oracle. In Visual Studio 2008, a feature called LINQ to SQL supports access to relational databases, but only for SQL Server and Microsoft Access. Rather than extending LINQ to SQL to non-Microsoft databases, Microsoft is telling developers to wrap non-Microsoft databases with Entity Framework models and then access the models using LINQ to Entities. This requires more work for developers than using LINQ to SQL, although it reduces the amount of infrastructure Microsoft has to build to support non-Microsoft databases.


ADO.NET Data Services. ADO.NET Data Services, which was code-named Astoria, makes data from SQL Server and other data sources accessible via URLs, using the same protocols, security mechanisms, and data formats as conventional Web sites and applications. The result is a data access service that works well with Web client applications, including Web services and Web-based client applications built with AJAX, Flash, or Silverlight.


In SP1, many tools, including both the Entity Framework and Data Services, support the most recent prerelease version of SQL Server 2008. The ASP.NET 3.5 Extensions, in contrast, supported only SQL Server 2005.


Deployment Simplified for Thick Clients

SP1 delivers a variety of improvements for developers creating thick client applications, in which code runs on a user's PC under control of the .NET Framework.


In particular, SP1 tries to facilitate deployment of the .NET Framework itself to client systems, addressing a problem that may have hampered adoption of thick clients that require the Framework. For example, SP1 includes a "client profile" subset of the .NET Framework that supports typical client applications but is much smaller (26MB) than the full .NET Framework (roughly 200MB), substantially reducing bandwidth and installation time. In addition, SP1 provides a 200K bootstrap installer for the .NET Framework that developers can distribute with their applications; when an administrator tries to install the application on a PC that lacks the .NET Framework, the bootstrap installer will detect the condition and arrange for download and installation of either the .NET Framework client profile or the full .NET Framework as required by the application. Developers can control many aspects of the bootstrap installer's behavior (e.g., where it gets files) by editing an XML configuration file.


SP1 includes a number of other changes for thick client applications. For example, default security policies have been loosened so that thick client applications can load and run normally from a network file server, enabling organizations to centralize storage and patching of such applications. SP1 also includes a new version of the Windows Presentation Foundation graphical user interface API, which adds useful new interface controls (such as an Office 2007-style Ribbon menu and an improved Internet browser control) and exploits graphics processors more effectively than previous versions.


Messaging, Team Foundation Server Updates Planned

Visual Studio 2008 SP1 will also deliver updates to a variety of other components, including the Windows Communication Foundation and Visual Studio Team System.


Windows Communication Foundation. The Communication Foundation messaging API enables developers to create Web services to tie together applications by message exchange and supports a variety of message formats and protocols. In SP1, the Communication Foundation will get a number of improvements. For example, Microsoft hopes to improve performance for Communication Foundation Web services up to tenfold when they are running on the latest version of the Internet Information Services Web server. In SP1, the Communication Foundation will enable Web services to send and receive a wider range of data types with less coding by developers and will support exchange of data defined by Entity Framework models, enabling developers to create Web services front ends to databases that they have modeled.


Team System. Visual Studio's source code control and task management features will get several user interface improvements, including the ability to drag and drop files from Windows Explorer into the source code control system. Microsoft also plans to improve migration from its older source code control system, SourceSafe, to Team System.


Compatibility Problems, Overlap Suggests Churn


Microsoft plans to ship the production version of Visual Studio 2008 SP1 in "late summer" of 2008, which suggests a September release. The current Visual Studio 2008 SP1 beta is incompatible with several other previews released at about the same time. Notably, it is not compatible with previews of Silverlight 2, the newest version of Microsoft's rich Internet application platform. Also, the Visual Studio 2008 SP1 beta requires Vista SP1 to be installed on Vista before it will run on the OS.


More generally, developers should note that there is considerable overlap among the SP1 technologies. For example, both the Entity Framework and the MVC framework employ data modeling and mapping tools. Similarly, LINQ to SQL covers much of the same ground as the more complex LINQ to Entities, leading some outside developers to propose that Microsoft support LINQ to SQL for non-Microsoft database platforms and eliminate much of the need for LINQ to Entities.


In general, overlaps among developer technologies increase the probability that Microsoft will eventually "deprecate" some technologies, slating them for less future development and support. Consequently, developers might want to start using the SP1 technologies on smaller, lower-risk projects to avoid betting big on technologies that might get limited future investment from Microsoft.



The Visual Studio 2008 SP1 beta (which also includes the .NET Framework 3.5 SP1) is at www.microsoft.com/downloads/details.aspx?FamilyId=CF99C752-1391-4BC3-BABC-86BC0B9E8E5A.

Bug fixes in SP1 and compatibility problems with the beta are documented at support.microsoft.com/kb/945140.

Entity Framework support for IBM DB2, Oracle, and other database technologies is summarized at blogs.msdn.com/sceppa/archive/2008/05/07/recent-ado-net-entity-framework-provider-news-demos-and-downloads.aspx.

The ASP.NET 3.5 Extensions are outlined in more detail in "ASP.NET Extensions Previewed" on page 19 of the Mar. 2008 Update.

LINQ and other .NET Framework 3.5 and Visual Studio 2008 features are summarized in the Jan. 2008 Research Report, "Visual Studio 2008 and the .NET Framework 3.5."

BizTalk Server Roadmap (Illustration)


Sunday, June 01, 2008

Matt Berseth ASP.NET Demo Gallery

Matt Berseth finally organized his great live demos links into a single web site.
Check it here: http://mattberseth2.com/demo/

My Public PageCast

I have been using PageFlakes (www.pageflakes.com) great free feature called PageCasts since 2007 and it’s really putting me up to date with the latest technology updates and news.

Before knowing PageCasts, I was spending a lot of time searching for new tech updates and news from different web sites. Of course I was aware of RSS but I never like any RSS tool.
I put the most active tech websites and blogs together into one page and it can be accessed from anywhere by anybody.

Check my public PageCast on (http://www.pageflakes.com/Sameeh)