dataGridView RowDataBound event

When working on a simple winForms application the other night, I wanted to manipulate some of the data being rendered on a row by row baisis. I soon found out that there is no equivalent RowDataBound event to the ASP.NET GridView event  in the winForms dataGridView control. Google-ing this i found a workaround in using […]

ASP.NET – How to format Currency in GridView

Most sources tell you that formating a column in a GridView is simple, all you need to do is use the DataFormatString Property like so: <asp:boundcolumn datafield=”Amount” headertext=”Amount” dataformatstring=”{0:c}”> However you may find that the currency format is not working in the GridView, this is because the GridView’s columns are being Html Encoded. A simple […]

Validation of web site address on server side using c-sharp and Regular expression

Validating web site address at server side in using c-sharp. A detail web site address  validation method where Regular expression is being used for a baisc web addrss validation, then web address is being splitted by dot and forward slash to check if it contains http: and if its defined more than once in […]

Remove extra spaces from string using regular expression,, c#

Removes extra space from the string using Regular expression. public static readonly RegexOptions Options =          RegexOptions.IgnorePatternWhitespace | RegexOptions.Singleline; public string RemoveExtaSpaces(string text) { Regex regex = new Regex(@”\s{2,}”, Options); text = regex.Replace(text.Trim(), ” “); //This line removes extra spaces and make space exactly one. //To remove the  space between the end of a word […]

Database, SQL (Structured Query Language)

Comments Off on Power of CLR (Common Language Runtime) + SQL server 2005, Managed Assembly

Power of CLR (Common Language Runtime) + SQL server 2005, Managed Assembly

Today I used Managed Assembly to use Regular Expression in SQL server 2005. I wanted to search for all records which contain special characters in my data and some foreign characters so I was using following SQL Query Select OrganisationId,organisationname from organisation Where organisationname like ‘%-%’ OR OrganisationName like ‘%&%’ OR OrganisationName like ‘%(%’ OR […]


Comments Off on Fill Array List with All properties of a class

Fill Array List with All properties of a class

Following Method/function will return list of class properties in an array list. PropertyInfo class is is used to get the properties of the object passed to the method parameter. You may need to add System.Refelection directive in your page. I am using this in my web development. Microsoft c-sharp , .net, .aspx private ArrayList getPropertis(object […], programming

Comments Off on Reqular experssion RegEx, C# , ,

Reqular experssion RegEx, C# , ,

Regular expression: Regular Expression is a great way to manipulate strings for example matching, finding, validating Data, Specailly string manipulaion becames handy while we use reqular expression. We can use Regular expression on both Serer and client side. We do use it with validation controls. Charcther matching: . ^ $ * + ? { […]

Comments Off on If you have to provide some services to all users of your website then….

If you have to provide some services to all users of your website then….

If you have to provide some data or services to all of your web users then best option is to put those data values into applicaiton object. This process will make your application very fast. You can use Global.asax  file and can use  following event.  Following code first puts value into a hashtable and then […]

Internet stuff

Comments Off on Free books on almost every topic

Free books on almost every topic You can find free books here on almost every topic. ajax, php, java, c#, asp, networking training, cisco network, photoshop, graphics, desing, web construction, business ebooks, SAP, oracle, mysql, mssql, .net, dot net, j2ee, j2me, linux, unix, windows, windows vista, office, database, programming, software development, video training, dreamweaver, flash, flash training, css, action script, […]