Skip to content
Loading
Asp.net form validation with angularjs  
  • class="form-row">  
  • class="form-group col-md-4 offset-2">  
  • "btnCreate" runat="server" class="btn btn-outline-primary btn-block secon-sh-btn-primary" data-ng-disabled="frmLanguage.$invalid" onserverclick="btnCreate_Click" ng-click="go();" value="Create">class="fa fa-check-square-o"> Create  
  •   
  • class="form-group col-md-4">  
  • "button" id="btnCancel" class="btn btn-outline-danger btn-block secon-sh-btn-danger">class="fa fa-times-circle-o"> Cancel  
  •   
  •   
  •   
  •   
  •   
  •   
  • "https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js">  
  • "https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.3/umd/popper.min.js">  
  • "https://maxcdn.bootstrapcdn.com/bootstrap/4.1.3/js/bootstrap.min.js">  
  • "https://code.angularjs.org/1.2.21/angular.js">  
  • "text/javascript">  
  • var app = angular.module('rouUtility', []);  
  • app.controller('MainCtrl'function ($scope) {  
  • // $scope.LanguageFont = "Arial Unicode MS";  
  • });  
  •   
  •   
  •   
  • Code Behind
    1. using System;  
    2. using System.Collections.Generic;  
    3. using System.Linq;  
    4. using System.Web;  
    5. using System.Web.UI;  
    6. using System.Web.UI.WebControls;  
    7. namespace Test  
    8. {  
    9. public partial class WebForm1 : System.Web.UI.Page  
    10. {  
    11. protected void Page_Load(object sender, EventArgs e)  
    12. {  
    13. }  
    14. protected void btnCreate_Click(object sender, EventArgs e)  
    15. {  
    16. string LanguageName = Request.Form["LanguageName"];  
    17. string LanguageFont = Request.Form["LanguageFont"];  
    18. string txtLanguageRemarks = Request.Form["LanguageRemarks"];  
    19. }  
    20. }  
    21. }  
    please someone help me out ....

    1 Reply

    Know the answer? Post it — somebody with the same question will find it here.