Posts

Showing posts from March, 2017

Constants in AngularJs

Image
Constants can be injected everywhere including configuration calls. So when you call module.config and set up states,colors,months,weeks or other run time settings you can inject constant values.

<!DOCTYPEhtml><htmlng-app="app"><head><title></title><metacharset="utf-8"/><scriptsrc="Scripts/angular.min.js"></script></head><bodyng-controller ="MyController">{{title}}<script>var app = angular.module('app', []);         // Storing a single constant value         app.constant('MOVIE_SAMPLE', 'The Movie');         // Now we inject our constant value into a My controller         app.controller('MyController', function ($scope, MOVIE_SAMPLE){ $scope.title=MOVIE_SAMPLE; }); </script></body></html>


Create and Execute a Simple PLINQ Query

Image

Pass user defined object to ASP.NET Webmethod from jQuery, using JSON