Author : Kumar

Home » Articles posted by Kumar

Complete ASPX HTML Source Codes:- <%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default8.aspx.cs" Inherits="Default8" %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head id="Head1" runat="server"> <title></title> <script src="//code.jquery.com/jquery-1.11.1.min.js" type="text/javascript"></script> <script type="text/javascript"> function ShowHideDiv() { //Get dropdown selected value var SelectedValue = $('#<%= ddlPaymentMode.ClientID %> option:selected').val(); // check selected value. if (SelectedValue == 0) { alert('Please ..

Read more

Complete ASPX HHTML Source Codes:- <%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default7.aspx.cs" Inherits="Default7" %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head id="Head1" runat="server"> <title></title> <script src="//code.jquery.com/jquery-1.11.1.min.js" type="text/javascript"></script> <script type="text/javascript"> $(document).ready(function () { $('#<%=cbAlternateEmail.ClientID%>').bind('click', function () { if ($(this).is(":checked")) { //Show the div $('#dvShowHide').show(); } else { //Hide the div $('#dvShowHide').hide(); //Clear textbox $('#<%=txtAlternateEmail.ClientID ..

Read more

Complete ASPX HTML Codes:- <%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default6.aspx.cs" Inherits="Default6" %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head id="Head1" runat="server"> <title></title> <script src="//code.jquery.com/jquery-1.11.1.min.js" type="text/javascript"></script> <script type="text/javascript"> $(document).ready(function () { $('#<%=rblPaymentMode.ClientID %>').click(function () { var SelectedValue = $('#<%=rblPaymentMode.ClientID %> input[type=radio]:checked').val(); if (SelectedValue == 1) { //If cash is selected then hide the ..

Read more

Complete ASPX HTML Codes:- <%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default5.aspx.cs" Inherits="Default5" %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head id="Head1" runat="server"> <title></title> <script src="http://code.jquery.com/jquery-1.11.1.js" type="text/javascript"></script> <script type="text/javascript"> $(document).ready(function () { //Check all/UncheckAll skills if Select All is Checked/UnChecked $("#<%=chkSelectAll.ClientID %>").click(function () { $("[id*=chkSkills] input:checkbox").prop('checked', this.checked); }); $("[id*=chkSkills] input:checkbox").click(function () { //If Select ..

Read more

Complete ASPX HTML Code:- <%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default4.aspx.cs" Inherits="Default4" %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head id="Head1" runat="server"> <title></title> <style type="text/css"> .error { border: 1px solid red; } .errorstyle { font-size: 16px; line-height: 22px; } .errorstyle ul li { margin-left: 5px; color: #ff0000; } </style> </head> <body> <form id="form1" ..

Read more

Complete ASPX Code:- %@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head id="Head1" runat="server"> <title></title> <script type="text/javascript" src="http://code.jquery.com/jquery-1.8.2.js"></script> <script src="Scripts/jquery.Jcrop.js" type="text/javascript"></script> <link href="CSS/jquery.Jcrop.css" rel="stylesheet" /> <script language="javascript" type="text/javascript"> $(document).ready(function () { $('#<%=imgToCrop.ClientID%>').Jcrop({ onSelect: getAreaToCrop }); }); function getAreaToCrop(c) { $('#XCoordinate').val(parseInt(c.x)); $('#YCoordinate').val(parseInt(c.y)); $('#Width').val(parseInt(c.w)); $('#Height').val(parseInt(c.h)); } </script> </head> ..

Read more

First Method:- <html xmlns="http://www.w3.org/1999/xhtml"> <head runat="server"> <title>Disable right click on web page using jQuery</title> <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script> <script type="text/javascript"> $(function () { $(this).on("contextmenu", function () { return false; }); }); </script> </head> <body> <form id="form1" runat="server"> <div> This is dummy text<br /> This is dummy text<br /> This is dummy text<br /> This is dummy text<br ..

Read more

Disable Right Click on All Images <html xmlns="http://www.w3.org/1999/xhtml"> <head runat="server"> <title>Disable right click on images on asp.net web page using jQuery</title> <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script> <script type="text/javascript"> $(function () { $('img').on("contextmenu", function () { return false; }); }); </script> </head> <body> <form id="form1" runat="server"> <div> <img src="http://c.saavncdn.com/801/Kick-Hindi-2014-500×500.jpg" /> <br /> This is dummy text<br /> This is ..

Read more

jQuery AJAX JSON example in Asp.net to insert data into sql server database without postback Table Schema:- CREATE TABLE BookDetails( [BookId] [int] IDENTITY(1,1) NOT NULL, [BookName] [varchar](100) NULL, [Author] [varchar](100) NULL, [BookTypeId] [int] NULL, [Price] [decimal](18, 2) NULL, CONSTRAINT [PK_BookDetails] PRIMARY KEY CLUSTERED ( [BookId] ASC )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = ..

Read more

Complete ASPX Code:- <%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default2.aspx.cs" Inherits="Default2" %> <html xmlns="http://www.w3.org/1999/xhtml"> <head id="Head1" runat="server"> <title></title> <style type="text/css"> .clsTxt { width: 200px; min-height: 25px; max-height: 200px; resize: none; } </style> <script> function resizeTextBox(txt) { txt.style.height = "1px"; txt.style.height = (1 + txt.scrollHeight) + "px"; } </script> </head> <body> <form id="form1" runat="server"> <div> <table> <tr> <td>Description: ..

Read more