Archives for November 2013

How to Program xLib using Mono

There are a lot of Unix/Linux tools today are coded in C/C++ which is against Xlib/X11. A migration to C# can be simplify the maintenance and few new opportunities, but the problem is, developers stick to their inherent environment. The change from the GUI development environment to Xlib/X11 to GTK or Qt has a lot of advantages like rapid prototyping and high level GUI elements.

In this article, we’ll show you how to access Xlib/X11 API from C# using Mono Develop. Most of the API calls are ready-to-use, defined, and test and some of the challenges are mastered. This post is aimed to verify that programming Xlib/X11 with C# can be easily achieved.

Read the rest of the post here:

Give Clarity to LINQ Queries by Extending Expressions

LinQ and Entity Frameworks are both commonly used in the .NET ecosystem, however, even well-written applications can have LINQ queries that are hard to understand. This is because LINQ is very flexible making it written in ways in which it fail to communicate with the developers intent. A well-written LINQ should be clear and self-documenting.

In this article, we’ll be showing you how to use pipe, filter, and rule pattern to make LINQ queries easier to understand. We will start by taking a look on how we can extend the Where method by creating custom filters which can take advantage of IQueryable extension methods. Then after that, we evaluate expression trees to understand how they work and how to manipulate it for maximum usability.

Read the rest of the post here:

Code Optimization Tools in Visual Studio 2013

Did you know that Visual Studio 2013 comes with code optimization tools? Development productivity is always a matter of concern for most developers especially in an organization. The biggest portion in spending in the development process is the code development because the number of people involved in the activity are very high compared to other roles.

IDE’s like Visual Studio helps improve such problem by playing a big role in providing high quality code and improving the productivity in coding at the same time. Visual Studio provides the tools that are built in to help create, edit, compile and debug the code.

Microsoft Visual Studio 2013 has included tools that provide visibility within the editor when someone is working on a project. It provides the status of the code,tests, and other components that give reference to code under inspection, etc.

Read the rest of the post here:

ASP.NET MVC5 New Authentication Filters

ASP.NET MVC5 has some wonderful improvements specifically around authentication. This includes new Authentication filter, Authentication options, and ASP.NET Identity management. We’ll take a look at the new authentication filters and how to use these to make authentication decisions.

However, at this stage, ASP.NET MVC does not provide any built-in authentication filters, but it offers you a framework to easily create your own custom authentication filters.

The new authentication filter provides a great way to customize authentication within ASP.NET MVC application. This provides a clear separation between authentication and authorization  filters.

Read the rest of the post here:

How to Crop an Image from the Center in ASP.NET Desktop App

When creating an app, there will be instances where you have to crop images at the center. For example, you need to store equally-sized avatar images for users but you don’t want to force users to crop their images, instead, allow them to use images in any dimension and process them at the server to create equal sized images. Another great example would be to allow the user to crop region in the simplest method possible.

In this article, we’ll show you the code, how it can be achieved and what you can do with it.

You can also view an example application for this tutorial.

Read the rest of the post here:

Build SPA with Angular and Breeze

Build Single Page Application (SPA) from scratch using JavaScript, Angular and Breeze. This tutorial will let you learn how to combine the Angular presentation framework, and the features of Breeze with raw features of JavaScript, HTML5, and CSS to create a robust, and modern web application.

The tutorial samples will use ASP.NET Web API, and Visual Studio; however, the majority of the focus will be on the front end which means front-end developers will benefit from this tutorial especially if you don’t have experience with ASP.NET and Visual Studio.

Jhon Papa will be the instructor for this course. He is a Sr. Technical Evangelist for Microsoft on Silverlight and Windows 8 client teams. Jhon is also a Microsoft Regional Director and the author of more than a hundred articles and 10 books.

Take the free tutorial here:

PhysicsJS, A JavaScript Physics Engine

Yes, you’ve heard it right, a Javascript Physics engine. Now you can add more elements and enhance the look and feel of your website through this engine. Sooner, or later, we’ll be able to see games made in JavaScript.

PhysicsJS is a modular, extendable, and easy-to-use physics engine for JavaScript. It is still under development which means the documentation also under construction.

Check out this demo page for some cool things a PhysicsJS can do.

PhysicsJS s modular so you can only use what you need thereby saving space and resources, it is extendable which means you can replace any functions with your own, and its is a library written in JavaScript which makes it more familiar with JavaScript developers.

Read the rest of the post here:

How to Display Calendar Appointments in an Agenda View with Telerik’s ASP.NET Ajax Scheduler Control

Gone are the days where you have to tirelessly code and enable users to view their appointments in Agenda view because with Telerik’s ASP.NET Scheduler Control, you can do that without having to code. This new feature will allow you to display appointments in single table. It is extremely lightweight in rendering and can support any browser.

The Agenda View offers several properties for controlling the overall appearance of the control. It gives you style and flexibility to however you need it to be.

If you haven’t tried the Agenda View yet, download it from your account in the BETA for the Q3 2013 release.


Read the rest of the post here:’

ViewData, ViewBag, and TempData

When working with ASP.NET MVC applications, you need to pass the data from controller action methods to the view. There are various techniques to do that, and these are through ViewData, ViewBag, and TempData.

Passing data to a view through a model or view model class is recommended and there are times where you need to pass arbitrary data to the view. Like when you need to pass a success or error message from a controller to a view so it can be rendered by the browser. Since the data is not a part of the model, you need some mechanism to pass it to the view.

This article explain the techniques and the difference with these three.


Read the rest of the tutorial here:

How to Integrate Tables into Java Web Application

If you are looking for ways to integrate into your java application, this example will give a more comprehensive one which can help control Datatables onto your Java code. The idea is to map all Datatables properties into Java Objects with the document from, the find a way to render table headers in either classical or annotation, then handle Ajax request sent from the table if the Datatables is set with server side processing.

However, in order to fully understand this example, you need to be familiar with Java, J2EE or the latest Java web application, DataTables,JSON, JavaScript, JQuery, and AJAX.

Read the rest of the tutorial here: