Showing posts with label Show all posts
Showing posts with label Show all posts

Sunday, July 29, 2012

Send multiple parameters in jquery ajax in

Here I am going explain how to send  multiple parameters using JQuery or JSON in
If we want to send or pass multiple parameters using JSON or JQuery in we need to declare it like as shown below in our aspx page under <script> tag.
Let's write a simple code to understand it.

Tuesday, July 24, 2012

What's New in ASP.NET 4.5 and Visual Web Developer 11 Developer Preview

This document lists options and enhancements that are being introduced in ASP.NET 4.5. It conjointly lists enhancements being created for internet development in Visual Studio (Visual internet Developer).

  1.     ASP.NET Core Runtime and Framework
  2.     Asynchronously Reading and Writing HTTP Requests and Responses.
  3.     Enhancements to HttpRequest handling
  4.     Asynchronously flushing a response
  5.     Support for await and Task-Based Asynchronous Modules and Handlers
  6.     Asynchronous HTTP modules
  7.     Asynchronous HTTP handlers
  8.     New ASP.NET Request Validation options
  9.     Deferred ("lazy") request validation
  10.    Support for unvalidated requests.

Sunday, July 22, 2012

Send Asynchronous Email in

Send Asynchronous Email in

when you are sending bulk email using then sending email using traditional parameter would be terribly time consuming as a result of we'll ought to expect the execution of smtp.send().but in Async methodology Email are going to be delivered in background and that we also can manage the output of email by Async handler.

Here i'm providing a code snippet to send email in Async manner.

using System.Web.Util;

     static void SendAsyncEmail()
            MailMessage cnetcode_mail = new MailMessage();            
            cnetcode_mail.From = new MailAddress("");
            cnetcode_mail.Subject = "your subject goes here";
            cnetcode_mail.Body = "Body content of the email.";
            //send the message
            SmtpClient smtp = new SmtpClient("Outgoing SMTP IP"); //Enter mail server address           
            object userState = cnetcode_mail;            
            smtp.SendCompleted += new SendCompletedEventHandler(SmtpClient_OnCompleted) 
            smtp.SendAsync( cnetcode_mail, userState );

Thursday, July 19, 2012


What is Favicon ?

when you open up a browser and visit a site you will see an icon on the tab

this is called favicon.Every time when we request a page it search for favicon.
It is a best practice to use favicon in also optimize performance of website a bit.
to use favicon just add this under <Head> tag

<link rel="shortcut icon" href="URL or path of your icon file"/>
Remember to replace
URL or path of your icon file file with your icon file's url.

Enjoy programming...:))

Wednesday, July 18, 2012

Visual Studio Build error

If you are facing problem to build your visual studio Application even if there was no syntax error then don't worry you just need to delete some temporary files.

Delete cache file of your project if problem in building.


C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files


Unlimited Connection TimeOut in and SQL

Sometimes when we are executing a Stored procedure from which takes a lot of time,which leads to connection TimeOut problem.
There are two ways to increase connection TimeOut.
1) From Web.config
2) From Sql Server database setting.

For got to web.config connection string and set Connection timeout Property to 0(Zero).

For Sql Server right click on Server => Properties . then a server properties page will open , from left hand side menu select Connections and set Remote query timeout to 0.

I hope somebody will find this useful.