Loading ...

ASP.NET Blogs | CodeAsp.Net

Who is online?  0 guests and 0 members
home  »  blogs  »  blogs: December 2010

Communifire Blogs

Blogs : December 2010 postings

Raghav Khunger

Get querystring values using jQuery

1/30/2011 by Raghav Khunger · 1 · 5436

In this blog I will show how to get querystring params values with jQuery. You must be familiar with getting params values in ASP.NET server side code but how to get it via jQuery? For this I have used REGEX to fetch the querystring param value based on param key. I have extended the jQuery function and made a getParamValue function for this purpose. Below is the code for plugin. $.exten...

Raghav Khunger

jQuery: Set focus to first textbox

1/29/2011 by Raghav Khunger · 0 · 2215

I have seen this question many times on how to set focus on first textbox of the page. I decided to write a blog on this. Below I have given the complete sample code where the cursor will be placed on first textbox when the page loads. <html xmlns="http://www.w3.org/1999/xhtml"> <head id="Head1" runat="server"> <title></title> <script type="text/javascript" src...

Raghav Khunger

How to clear dropdown list using jQuery

2/1/2011 by Raghav Khunger · 0 · 2460

In this blog I will show how to clear dropdown list with jQuery . Today I saw a person was asking on forums on how to remove all the items of dropdown list with jQuery. I decided to write a blog on this. Below is the sample code for it: <html xmlns="http://www.w3.org/1999/xhtml"> <head id="Head1" runat="server"> <title></title> <script type="text/javascript" sr...

Raghav Khunger

Disable right click with jQuery

1/31/2011 by Raghav Khunger · 1 · 1818

In this blog how to disable right click with jQuery. I saw today, a person was asking on forums on how to stop right click on web page, I decided to write a quick blog on it. Whenever right click is occurred the contextmenu event fires and we can prevent the default action of that event in order to disable the right click. Below is the complete sample code: <html xmlns="http://www.w3....

Raghav Khunger

jQuery: Get word count of textbox

2/1/2011 by Raghav Khunger · 0 · 2161

In this blog I will show how to show word count of the textbox with jQuery. A person asked me on the forums on how to show the word count , I decided to write a quick blog on this. The logic for getting the count is simple. We will split the text of textbox on the basis of empty spaces in it and on the basis of that we will get the count. Below is the sample code for it: <html xmlns="...

Raghav Khunger

Set default tab for jQuery UI tabs

1/28/2011 by Raghav Khunger · 1 · 2437

In this blog I will show how to set default tab for jQuery UI tabs. You must be aware of that by default the first tab is opened for jQuery UI tabs. If we want that instead of first tab some other tab should open, we have to set the selected property of tabs plugin with the index of that tab which we want to open by default. Below is the complete sample code for it: <html xmlns="http:...

Hajan Selmani

NDepend tool – Why every developer working with Visual Studio.NET must try it!

12/17/2010 by Hajan Selmani · 0 · 1048

In the past two months, I’ve had chance to test the capabilities and features of the amazing NDepend tool designed to help you make your .NET code better, more beautiful and achieve high code quality. In other words, this tool will definitely help you harmonize your code. I mean, you’ve probably heard about Chaos Theory. Experienced developers and architects are already advocates of the ...

Hajan Selmani

jQuery Templates in ASP.NET - Blogs Series

12/16/2010 by Hajan Selmani · 4 · 1578

In the previous days, I wrote several blog posts related to the great jQuery Templates plugin showing various examples that might help you get started working with the plugin in ASP.NET and VS.NET environment. Here is the list of all five blogs: Introduction to jQuery Templates jQuery Templates - tmpl(), template() and tmplItem() jQuery Templates - {Supported Tags} jQuery Templates with ...

Hajan Selmani

Get Application's Web.config connection string when working with LINQ2SQL created on a Class Library

12/15/2010 by Hajan Selmani · 1 · 1589

In the asp.net forums one user asked how to get Web.config's connection string value when using LINQ2SQL which is created inside another Class library project. We know that if you use the System.Configuration classes, you will access the web.config from the application. Therefor, the first thing needed here is to reference the System.Configuration.dll inside the class library project (wh...

Edgar Flores Palma

Communication Master Page and ContentPlaceHolder

12/15/2010 by Edgar Flores Palma · 0 · 1565

Recently a coworker had a problem. "He wanted to have a button on the Master Page with which to select the button invokes a function that is within the ContentPlaceHolder " Steps : Create a Master Page Master Code using System; using System.Data; using System.Configuration; using System.Collections; using System.Web; using System.Web.Security; using System.Web.UI; using System.Web.UI.Web...

Raghav Khunger

How to escape single quotes in JavaScript

12/15/2010 by Raghav Khunger · 0 · 5727

Today I was in a need to escape single quotes in a string in JavaScript. When we write strings in JavaScript, we have two options either we can write them in single quotes or in double quotes. We should not mix them by starting with one of them and ending with the other option. We can write strings in this way var foo = 'this is test'; var foo = "this is test"; Now the issue comes when w...

Raghav Khunger

Hide skype from taskbar in Windows 7

12/14/2010 by Raghav Khunger · 0 · 2109

If you have Skype of version 4.2 or greater, you will be facing the issue of how to hide or remove the Skype icon from the task bar when you have closed the main window. In previous versions of Skype, for example Skype 4.1, 4.0 and 3.0, when the main window was closed, Skype was minimized to system tray (notification area which is adjacent to clock on Windows Taskbar). But in newer versi...

Hajan Selmani

Retrieve data from database using ASP.NET MVC and jQuery $.getJSON Method

12/14/2010 by Hajan Selmani · 2 · 7535

The JSON (JavaScript Object Notation) data-interchange format is becoming very popular because it's lightweight and it can be easily serialized into HTML, especially using jQuery Templates. In real-world scenarios, the data usualy comes from databases. Using ASP.NET with jQuery, you can make ajax requests easy. When using ASP.NET Webforms, to make one method available to work with ajax r...

Hajan Selmani

JsonResult Class in ASP.NET MVC

12/14/2010 by Hajan Selmani · 0 · 2187

JsonResult Class is a type of class that is used to send JSON-formatted content to the response. This class belongs to the System.Web.Mvc namespace so that it's part of the ASP.NET MVC Framework. The JsonResult class inherits from ActionResult. JsonResult class has the following members: - JsonResult constructors which initializes new object of the class - ExecuteResult method - method t...

Raghav Khunger

jQuery Datepicker: Display on image click

12/14/2010 by Raghav Khunger · 1 · 7878

In this blog I will show you how to open or display jQuery datepicker on image's click instead of focus on the textbox. To accomplish it I have used the showOn property of the jQuery datepicker and set it to 'button' to make that happen. The src of the image is set via buttonImage property. Below is the sample code: <html xmlns="http://www.w3.org/1999/xhtml"> <head id="Head1" ru...

Hajan Selmani

Addition of jQuery UI in ASP.NET MVC 3

12/12/2010 by Hajan Selmani · 0 · 7897

In ASP.NET MVC 3 - Release Candidate 2, the jQuery UI library is added together with the ASP.NET MVC 3 application project you are going to create. Besides this, the newest version of jQuery library is also shipped (currently v1.4.4). This is great since we see that Microsoft also supports the jQuery UI project too. One thing that misses for now is to include the jQuery UI CSS Styles and...

Hajan Selmani

ASP.NET MVC 3 - RC 2

12/11/2010 by Hajan Selmani · 0 · 1103

I've just read a blog post by Scott Guthrie announcing the ASP.NET MVC 3 - Release Candidate 2, where he has listed many interesting features that this RC 2 includes. As he says, this is the near-final release of ASP.NET MVC 3. You can read the complete blog post here .

Hajan Selmani

Coding standards and why its important to use them

12/9/2010 by Hajan Selmani · 1 · 1280

Everyone develops his own style of writing code, approaching problems that come up in our daily coding life, but is everyone following a concrete coding standards set by the organization, the company where he works? In the company where I've started working about one month ago, there are very good defined coding standards that help teams share their code and understand other developer's ...

Shaitender Singh

Client-side scripting : Developer tools

12/10/2010 by Shaitender Singh · 0 · 820

Normal 0 false false false MicrosoftInternetExplorer4 In this blog, I will share few useful developer tools for client side scripting . I believe any little help is very helpful in programming . Here is the list of developer tools: JSFIDDLE : Great tool to test JS/JQuery/YUI etc , this is online tool which mean you don’t need to open VS or need VS in your system to test / make code snipp...

Shaitender Singh

Jquery plugin : Fast confirm like javascript confirm

12/9/2010 by Shaitender Singh · 0 · 2791

Normal 0 false false false MicrosoftInternetExplorer4 In my recent project, client demanded that confirm button text should be ‘Yes’ and ‘No’ instead of ‘O’ and cancel. I have gone through many forums posts amd tried out many things to to change text of JS Confrim box button but didn’t succeed.Even tried vbscript ( Stackoverflow : Javscript Confirm ) , but it didn’t work in FF and Chrome...

Raghav Khunger

How to install ASP.NET membership database

12/5/2010 by Raghav Khunger · 0 · 2558

In this blog I will show how to install ASP.NET membership database on SQL Server. We are going to use the ASP.NET SQL Server Registration tool (Aspnet_regsql.exe) to create ASP.NET membership database. The Aspnet_regsql.exe file is located in the [drive:]\%windir%\Microsoft.NET\Framework\version folder on your Web server. For my case it was at following path C:\WINDOWS\Microsoft.NET\Fra...

Raghav Khunger

Convert JSON date to JavaScript date

12/5/2010 by Raghav Khunger · 0 · 7230

In this blog I will show how to convert the JSON date (returned from .NET server side) to JavaScript date. This is one of the most common requirement while dealing with dates returned from ASP.Net AJAX. The dates returned from server side are in this format /Date(milliseconds)/ . Below is the screenshot showing how dates are returned via ASP.NET ajax from server side: Our goal is to conv...

Hajan Selmani

Announcing Silverlight 5

12/2/2010 by Hajan Selmani · 0 · 725

It is interesting that today Scott Guthrie wrote a blog post announcing the Silverlight 5. All Silverlight developers should be exited since the new version of Silverlight adds significiant new features and capabilities. More about this you can read at Scott Guthrie's blog post, link: http://weblogs.asp.net/scottgu/archive/2010/12/02/announcing-silverlight-5.aspx

Edgar Flores Palma

Maintain Active Session Indefinitely with JQuery in Asp.Net

12/1/2010 by Edgar Flores Palma · 2 · 1736

Introduction The aim of the article is to demonstrate how using asynchronous calls made using the jQuery library can maintain an active Session on the server indefinitely without it expires at a time. Maintain Active Session Asp.net Session expire a user when a prolonged period would indicate that no longer is using the page, but sometimes it is necessary to allow the user to take severa...

Page 1 of 1 (24 items)

Product Spotlight

ASP.NET Hosting Spotlight

Join CodeAsp.Net for FREE Today!

It's fast, easy and free! Submit articles, get your own blog, ask questions & give answers in the forums, and become a better developer, faster.

enter your email address:

 

Quick Vote

What kind of email newsletter would you prefer to receive from CodeAsp.Net?