Menu

Category: Asp.net

How to create jquery ajax call in Asp.net

How to create Jquery ajax call in Asp.net just add jquery in header. <script src=’https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js’></script> then add ajax call method in your header. var data_string = ‘EmailId=’+ EmailId +’&IsChecked=’+ IsChecked; $.ajax({ url:’UpdateUser’, data:data_string, type:’get’, cache:false, success:function(data){ alert(data); }, error:function(){ alert(‘error’); } } );   data_string is variable where you will write your data which you […]

 

0 Comments
Read Full

Validation of viewstate MAC failed. If this application is hosted by a Web Farm or cluster, ensure that configuration specifies the same validationKey and validation algorithm. AutoGenerate cannot be used in a cluster.

Validation of viewstate MAC failed. If this application is hosted by a Web Farm or cluster, ensure that <machineKey> configuration specifies the same validationKey and validation algorithm. AutoGenerate cannot be used in a cluster. Hey Guys if you find this error please do following. First add this line in your web.config. <system.web> <machineKey validationKey=”1234567890123456789012345678901234567890AAAAAAAAAA” decryptionKey=”123456789012345678901234567890123456789012345678″ […]

 

0 Comments
Read Full

How to increase timeout in asp.net fileupload

how to increase timeout in asp.net fileupload. 90000 MaxRequestLength is about to 90 MB of your file length put this line in your web.config file like this. <system.web> <httpRuntime maxRequestLength=”90000″ executionTimeout=”200″/> </system.web>  

 

0 Comments
Read Full

Increase session timeout in asp.net web.config

how to increase the session timeout in asp.net web.config. Simply write this line in your web.config file. 20 is 20 minutes. <system.web> <sessionState mode=”StateServer” cookieless=”false” timeout=”20″ /> </system.web>  

 

0 Comments
Read Full

Asp.net updatepanel postback javascript(resolved)

when update panel postback javascript or jquery not working (resolved) add your script like this  On head script <script> function GetData() { alert(test after post back working and on load); }); </script> then add in your update panel <asp:UpdatePanel ID=”UpdatePanel1″ runat=”server” UpdateMode=”Conditional”> <ContentTemplate> <script type=”text/javascript”> Sys.Application.add_load(GetData); </script> <div> <table class=”style1″> Please do comments if you […]

 

0 Comments
Read Full

Basic angular js

Basic angular js First Add this in head <script src=”https://ajax.googleapis.com/ajax/libs/angularjs/1.6.4/angular.min.js”></script> Then  Add it to body <div ng-app=””> <p>input box</p> <p>Xyz your text : <input type=”text” ng-model=”xyz” placeholder=”xyz enter here”></p> <h1>here is your text {{xyz}}</h1> </div> Please Follow us for more  

 

0 Comments
Read Full

Bootstrap basic

First of all Add link in head. <meta name=”viewport” content=”width=device-width, initial-scale=1″> <link rel=”stylesheet” href=”https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css”> <script src=”https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js”></script> <script src=”https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js”></script> Then first create container in div then row in div  and then column show you example below. i will define how column md sm lg next post.   In body <div class=”container”>   <div class=”row”>     […]

 

3 Comments
Read Full