Friday, 20 May 2016

Visual studio shortcut keys.

Find out the Visual studio shortcut keys which helps in day to day development activity and makes your development fast. These visual studio shortcut keys and just common keys to use.


SNO
Short Cut Key
Description
1
Ctrl+C , Ctrl+Ins
Copy Content
2
Ctrl+X, Shift+Del
Cut content
3
Ctrl+V, Shift+Ins
Paste content
4
Ctrl+Shift+V, Ctrl+Shift+Ins
Cycle Clipboard Ring, paste the multiple copy content
5
Del, Ctrl+Del
Delete

Thursday, 19 May 2016

Javascript Interview Question

1.       What is JavaScript?
2.       What is feature of JavaScript?
3.       Where we can use JavaScript.
4.       What Advantage and Disadvantage of JavaScript?
5.       What is difference in JavaScript and Asp Script and which is faster.
6.       Which has invented JavaScript?
7.       How to defined variable in JavaScript?
8.       What is Undeclared and undefined variables?
9.       What is global variable in Javascript?

Tuesday, 3 May 2016

AngularJs Service, Factories and Providers

 Service in AngularJS

AngularJs Service, Factories and providers are all injectable types.
An AngularJs service encapsulates specific business logic & exposes an API to be used by other components to invoke this logic.

e.g. $timeout service executes function after specifies interval. $http service encapsulates the logic required to interact with REST backbends.

AngularJS service is always Singleton.

Service is registered using service function of angular.module().
The Second argument to service() is a constructor function to inject the service.

Tuesday, 12 April 2016

encode and decode query string asp.net

Use below code to encode the query string using AntiXSS library for it you need to refer the antixss library in your code.

What is Antixsslibrary ?
It helps you to protect your code from cross site scripting. It helps to encode the text.
Cross site scripting (XSS) occurs  mostly on  due following .
1. When Dynamically data changing.
2. Passing the data through query string.
3. Displaying data to UI which is allowing to insert from user (they can insert the script aswell)
4. Showing any messages to UI.

clear controls in asp.net

Suppose you have the list of input control that you want to clear it after saving the records or updating the records, you can use the generic method and that you can call from your derived class and pass the control.

Use below method  for same it will clear your input control from C# code behind.

Tuesday, 29 March 2016

Simple Crud Operation Using AngularJS.

A step by step and simple demonstration of doing the crud operation in AngularJS.
Create a simple form like  below.

1.       Defined the Ng-App and Ng-Controller at top.

Tuesday, 22 March 2016

Custom Filter in AngularJS

1. What is Filter in AngularJS.
AngularJs provide the in build filter which will modify your output. There are  certain inbuilt filters like.
LowerCase : which will change the output as lower case.
Upper Case : which will change the output as Upper case
Number : which will change it to number type.
Currency : Convert out put to currency type.

On the same line AngularJS give the facility to extend the filter and we can create our own custom filter.

2. What is Custom Filters.
Create your own filter to modify the output.
Lets see the two type of custom filter in AngularJs which is very simple to understand and Helpful to know of the custom filter will create.

Sunday, 6 March 2016

Top 30 angularjs interview questions

1.       What is AngularJs?
AngularJs is a JavaScript framework which we use to create highly scalable client application & simplifies the binding of JS object with HTML elements. It extends the syntax of HTML to express application components. It extends the HTML extension using the attributes e.g. ng-
<div ng-app>
Angular JS provides many attributes which extend the feature but all of them start with ng-.

2.       What is the key features of AngularJs
AngularJs come with lots of flexibility and features like:
a.       Two way data bindings
b.      Scope
c.       Follow MVC patterns
d.      Injectable Types (like Service, factory, Providers)
e.      Directive
f.        Filters

Thursday, 18 February 2016

VS2015 New Features

1.       Download Visual studio community version as free.
Use below link to get the download page. Microsoft announce for open source of community version of VS2015.


Wednesday, 17 February 2016

Dependency Injection in MVC using Unity


What is dependency Injection?

Dependency Injection makes your application as decoupled and loosely couple to your code. It use to resolving the dependency of your code. It follow the Dependency Inversion principle of SOLID.
This is the way of injecting the code based on the feature required in application.
There are basically three ways you can approach to implement the dependency Injection.

1.       Using Property Getter and setter
2.       Using Constructor.
3.       Through Interface.


How Implement the Dependency Injection in MVC using Unity?