Q:

how to remove Error: [ng:areq] with angularjs in MVC..?

how to remove Error with angularjs in MVC..?!

i'm creating a web app in angularjs MVC
i have add all the reference for angular script files
i write code in separate javascript file as AdminController.js, i have also referenced it on view, but i'm not able to trigger angularjs controller's method on the view.
my AdminCtrl.js code is as:
 var adminModule = angular.module('angApp', []);
//Defining a Angular Controller
adminModule.controller('AdminCtrl', ['$scope', '$http', function ($scope, $http) {
//Retrieving the List of people
Login();
function Login(U_Name, U_PWD) {
    //Defining the $http service for login the admin user
    $http({
        method: 'POST',
        url: '/Models/AdminModels',
        data: {User_Name:U_Name,User_PWD:U_PWD}
    }).success(function (result) {

        if (result == true){
            alert('user is valid');
        }
        else {
            alert('unauthorised access!');
        }
    })
          }
}]);

please suggest me for the best option so that i can perform my task,
thanks in advance.

A:

i did only a little bit mistake, i was binding ng-app to  but in the sense it should be bind with  now it's working.
my new code like as  .....
   <body ng-app="angApp">
   <script src="Scripts/app/AdminCtrl.js"></script>

   <div id="alert" class="alert"></div>
   <div ng-controller="AdminCtrl">

        <div class="admin-login">
            <h2>using angularjs</h2>
            <input type="text" id="txtUserAng" placeholder="User Name" ng-model="U_Name" />
            <input type="password" id="txtPWDAng" placeholder="Password" ng-model="U_PWD" />
            <input type="button" id="login" value="login" ng-click="Login()" />

        </div>

    </div>
</div>

