Archives
-
Using Visual Studio Debugger Attributes
Visual Studio provides a rich debugging experience to developers, helping them write robust and bug free code. In simple projects, the inbuilt facilities of Visual Studio debugger may be sufficient for your purpose, however, while debugging complex projects you may want to enhance the debugging experience further. Luckily, Visual Studio offers debugger attributes that help you do just that. Debugger attributes allow you to customize the way Visual Studio debugger steps through your code and also the display of your types. This article explains some of the important debugger attributes along with debugger type proxies and visualizers.
-
Create a Simple Task-List Application Using ASP.NET, WCF, and jQuery, Part 2
In the first part of this two-part series, published in the June 2011 issue, we developed a Windows Communication Foundation (WCF) service that takes data in and out of the Tasks table. We created a web form for displaying the tasks in a tabular format using the jQuery Templates plug-in. Finally, we developed a DatePicker plug-in to pick due dates. In this second part, we'll make the task-list application functional by writing jQuery code, including a few helper functions, code to call WCF service methods, and code to filter the task-list table.
-
Using DynamicObject and ExpandoObject
C# is primarily a statically typed language. That means the compiler needs to know in advance about the data type of a variable. In the absence of this information, the compiler will throw a compilation error and will refuse to compile the code. In spite of the advantages offered by the statically typed languages, dynamic languages have their own place in application development. For example, most of the web sites developed today make use of JavaScript in some way or the other. Languages such as Python and Ruby are also popular amongst developers. The C# language now supports dynamic features through Dynamic Language Runtime (DLR). Part of these features include dynamic types, DynamicObject Class and ExpandoObject Class. This article explains these features and provides examples illustrating how these features are used.
-
Working with URL Routing in ASP.NET Web Forms
While developing web sites, at times you require that the URLs being used are not mapped to any physical file. For example, you might be building a blog engine that stores all blog posts in a SQL Server database but while displaying these posts you want URLs to be SEO friendly. In such cases the resource pointed to by the URL has no physical existence. That's where the URL Routing features of ASP.NET come to the rescue. In addition to creating SEO friendly URLs these features also help you render easy to remember URLs. ASP.NET MVC relies heavily on the URL Routing feature. However, it is also possible to use URL Routing in web forms. In this tutorial you will learn just that.
-
Working with Query Extender control
Many ASP.NET websites allow users to filter data presented to them on the basis of certain conditions. A general approach used in such cases is to re-construct the database query again and again for each such filter parameter. Though this works well as far as end user requirements are concerned, it can make your code a bit tricky and cumbersome to manage. This is because you need to manipulate the WHERE parameters of the data source control under consideration (LINQ Data Source for example) in your source code. That is where the Query Extender control comes handy. The ASP.NET Query Extender server control allows you to filter data retrieved from a data source without changing the underlying query. It does so using a declarative syntax without any need to programmatically manipulate query parameters. This article explores the Query Extender control with the help of several examples.
-
Create a Simple Task List Using ASP.NET, WCF, and jQuery, Part 1
Maintaining a task list (or to-do list) is a common time management technique that keeps track of work items to be completed along with their priority and current status. No wonder that task manager is often an integral part of web and desktop calendaring applications. In this two part article we will build our own task list application using jQuery, ASP.NET and WCF. Though simple our task list application will illustrate how jQuery can interact with server data through WCF services. We will also get to use several jQuery concepts such selectors, AJAX calls and plug-ins.
-
Understanding ASP.NET MVC Model Binding
ASP.NET MVC model binding allows you to map and bind HTTP request data with a model. Model binding makes it easy for you to work with form data because the request data (POST/GET) is automatically transferred into a data model you specify. ASP.NET MVC accomplishes this behind the scenes with the help of Default Binder. This article discusses how model binding works for various types of models viz. simple types, class types and lists. It also shows how to create a custom model binder if situation calls for it.