You are hereC#

C#


rahul's picture

.Net - Compressing directories recursively with ICSharpCode.SharpZipLib

I think there's hardly anything to explain here or give introduction about, the title says it all. I wrote a small function to zip directories recursively using the free and open-source ICSharpCode.SharpZipLib library.

So without saying many more things, here's the function:

 

rahul's picture

Ext.Net - Controlling core css and javascript files rendered on the page

Our designer had created a comprehensive custom theme for ExtJs, and we wanted to use it in our ASP.NET app that leverages Ext.Net and ExtJs extensively.

If you have used Ext.Net, you would know that all ExtJs resources are embedded in Ext.Net.dll assembly that are automatically put on the page whenever you add an <ext:ResourceManager /> to the page. This includes the core ExtJs css and javascript resources (including current ExtJs theme's resources), plus Ext.Net's own resources (providing extensions/enhancements to Ext classes).

rahul's picture

ExtJs and Ext.Net - Creating Ext.Net server components for custom ExtJs javascript components

I think all of us would agree that Ext.Net provides too good (and a bit complex) ExtJs and ASP.NET integration. It exposes almost all ExtJs toolkit classes server-side in ASP.NET and many of the popular extensions too. In addition, it provides own custom components that are useful (e.g. MultiCombo, Linkbutton etc).

rahul's picture

SharpSvn - Connecting and fetching logs from Remote repositories

In continuation to my pevious blog post on defining configuration path to connect to remote repos using SharpSvn, I present quick sample code for connecting to and fetching logs from a remote svn repo requiring authentication.

The topic as such should not need much introduction, so here's the plain sample code:

 

rahul's picture

SharpSvn - SharpSvn.SvnFormatException: Can't determine the user's config path

Till the beginning of this month, I was a regular SVN user using SVN as my Version Control System for many projects. But then, somewhere in the second week of this month, I have turned a SVN developer (not writing code for SVN itself, but providing solutions off SVN).

For one of the projects code-named Zone, I began writing a module for SVN integration to provide seamless access to local or remote SVN repositories. Without second thought, CollabNet's open-source SharpSvn library was my library of choice for SVN development.

rahul's picture

ASP.NET - A complete translation framework through Powershell and Google Translate

In this blog post, I present a complete framework for automatic localization in ASP.NET, ability to customize what is produced by this framework and a completely functional ASP.NET app demonstrating the features and process.

rahul's picture

Serializing/Deserializing .Net's native RSA Public/Private keys

Okay, here's the second consecutive blog post on serializing/deserializing RSA public/private keys, this time generated by the native RSACryptoServiceProvider available in .Net (the previous post available here related to serializing keys generated by open-source Bounty Castle library).

rahul's picture

Serializing/Deserializing RSA Public/Private keys generated using Bounty Castle library

.Net provides a good Cryptographic framework in the System.Security.Cryptography namepsace. But I have sometimes found it lacking for my needs (and non-intuitive at some other times).

Yesterday I needed to generate a RSA Public-Private key pair in a client-server communication, where the server generates the key pair and sends off the public key to the client, which the client subsequently uses to encrypt data being sent to the server. The server stores the Private key in the database used later to decrypt data received from the client and then send the encrypted response to it.

rahul's picture

.Net - Regex pattern for lazy balanced group matching

A couple of days ago, I needed to find all calls to a specific method in a large number of javascript files. The exact method call looked something like following:

Rahul.t('String to be translated.');

rahul's picture

ASP.NET - Converting a Physical Path to a app relative Virtual Path

I had earlier written a quick and dirty method to convert a Physical path to a virtual path (aka a url) that can be used on the client after passing through ASP.NET's ResolveUrl method. Without much talking, here's the method:

 

Recent comments