Update Title and Meta Tags Dynamically in ASP.NET
If you are using master pages, updating your title or meta tags (such as “description” and “keywords”) may become an important subject because of the SEO purposes. Since there are several ways to accomplish this, here is my way in C# to do so.

Rotate Array by N Position - Via Programming Pearls
Lately, I have been trying to finish reading the Programming Pearls written by John Bentley. The chapters related with designing and developing algorithms are really entertaining. One of the questions that was discussed in the early chapters of the book was about an algorithm of rotating a one-dimensional vector, and I want to share my solution written in VB.NET and C# by utilizing a simple string array.
Question (with the terms of an array)
Rotate a one-dimensional array of K elements from left by N positions.
For instance, with K=7 and N=3, the array {a, b, c, d, e, f, g} is rotated to {d, e, f, g, a, b, c}.
Solution
As suggested in the book, I will be using the Array.Reverse method. I will also write the function that rotates an array from right as well in order to carry out the discussion further.
In VB.NET - Rotate By N From Left

In C# - Rotate By N From Left

In VB.NET - Rotate By N From Right

In C# - Rotate By N From Right

Page_Load of an ASP.NET environment would be a good place to test and visualize the results in this case.
In VB.NET

In C#

Finally, results on the browser should be like:

Utilize Read-Only TextBoxes in FileUpload Control of ASP.NET
Nowadays, I am spending most of my work time on developing a “document depot” type of web application which has a heavy usage of FileUpload control. And, it was one of the requirements that users should not be able to modify the associated textbox after browsing the document from their hard drives. I believe it is a very good user-experience practice and it avoids some possible security issues as well. After walking around between some search results, I have found the following solution by assuming that FileUpload1 is the ID of the control:

VB.NET:

C#:

As a result, users would be able to select a document only by using the Browse button.
I have tested the sample code with the latest versions of IE and Firefox, and everything seemed to be working fine with both browsers.
Manipulating ColSpan Attribute of Footer Row in GridView
There may be some cases that the Footer of a GridView is desired to be displayed as one cell, which means setting the ColumnSpan property of the Footer’s first cell to the number of columns of the GridView. As there are some other possible workarounds to accomplish this, here is my way by adding a few lines to the OnRowCreated method.
First, make sure that ShowFooter property of the GridView is set to True:

VB.NET:

C#:
