Few line for Developer’s; Must Read !!!

We are the developer who working today with different technology. Every day handling different situation; and also getting different problem where we might think that we are getting stuck after doing many search over internet; now it’s time to take help for some one else.
Is not it ??
Yes; so what we do is ask some one other developer or any of our friends Right ?
But, still we are not finding any solution then ???
If you ask me then I have answer.
My answer is visiting any technical Forum and asks the same question there.
Who are new to .Net technology might be do not know about what is forum ??

and how it is working ?
Let me tell you;

Today we have lots of technical forum to ask the question; if you are working on .Net technology then we have specific forum for each technology. Today’s many developer are actively answering the question and what I saw one of the best technical forum for web development is Asp.net forum.
Apart from that another best one for any Microsoft technology related query is MSDN.Com.
You can ask any question/doubts there.
Don’t think that you can get answer immediately ; yes you can get the answer immediately if and only if you ask the question in appropriate manner.

So what I mean by appropriate manner?

    • Your question not so much lengthy explanation with unnecessary things; so make as much as smaller and keep it as simple.
    • Post your code if you think explanation required code stuff to understand.
    • Always choose the appropriate categories while posting the question that is most important.

So don’t be hesitated to asking your question; it’s not like that you can get your response quickly; but remember you definitely get the answer as depends upon how you explain the question. What I saw in my case maximum within four to five hour I get the response. So keep penance!!!
I am not saying that you can improve your way of asking question in one day but if you do it regularly then definitely I say you can improve a lot and you get quick response from other developers.
If you are asking question in Asp.net forum and MSDN forum then I definitely sure that you can get response to your question; in rare case you can not get; but most probably all the question get solved very quickly.

How it’s working ?
Many of us actually don’t know how the forum works; it’s not like that you are only asking question and getting response; behind the seance there are lots of stuff happen;
Basically if you are asking question in any Microsoft forum then Microsoft has it’s own moderator (moderator are the developer who have lots of experience and actively working with community and also their are various Microsoft Most Valuable Professional  (MVP))who are going to check your question whether your question related to Microsoft technology or not and also they check on which categories you are asking question. If they found any point of time your question is invalid then they can immediately remove it from forum and they send you a private message about this.
So keep in Mind this while posting question!!!
Many developer today actively contributing their valuable response in MSDN forum.
Which makes you guarantee that you get your response quickly.

If you see that many days happen you are not getting any response of your question or valid answer of your question then the best way is just open another thread and ask same question in different manner.

Last one for all; Use forum also answer the question as well; not only ask the question. So do regular visit to forum and try to read the question as you can; and on the way of reading one by one question when you feel that you can answer it just answer it by click on reply.
If you do so you are now actively work with community on a bidirectional manner.

Last but Not the List:-
We all asking the question but it’s important to keep in mind that once your question get resolved make the question mark as answer so it’s helps the community to recognize that what are the question resolved till the date. A part from that if you mark as answer then it means that you are actively engaged with that thread.

If you are belong to .Net Techies then;
Some of the best forum where you get directly in by just simple sign in:-
1) All in One as I told above i.e. is MSDN Forum
2) If specific to web technology then Asp.net Forum
3) C# Corner Forum
4) CodeProject Forum

So what we see form above that we are not alone today we have whole community with us.
If we are working on .Net technology then we have many more developer from across the country whom we can get collaborate by asking the question and get the response.
Keep asking and visiting forum.
That’s all;
Hope above information help you.
You can find my thread on MSDN forum Here

Please give me your valuable feedback and tell me if any thing i left here.


Happy Coading. 🙂


Patterns in Java Script

Introduction :-

In Java script we have different  types of pattern to write our code.  We all web developer write many java script code every day and we do not know how much clean and safety our code. So today in this article I am going to tell you about basic JS Patterns which helps to write an effective java script code; and we also going to see many OOPs concept while we go through the different patterns.

Background :-

Let’s starts a deep drive in to Java script patterns;

We have three types of pattern in JavaScript these are :-

  1. Function as Abstraction Pattern.(Abstraction in Java script)
  2. Function to Build Module Pattern. (Encapsulation in Java script)
  3. Function to avoid Global variable Pattern. (Anonymous function in Java script)

Let’s see one by one with live examples;

  1. Function as Abstraction Pattern:-

If you are coming from C# language or any object oriented programming language background then we probably all know about abstraction.

Let me once again quick remind!!!

Abstraction :-  Hidings the details and providing only what is necessary.

To understand above let’s jumps to our demo;

Note :- Here I am not going to create any project in visual studio. You can use any editor to write this simple java script function or else you directly open you browser window and open the console window in browser by pressing F12 then press CTL+L in Chrome and CTL+Shift+L in Firefox to clear the console window and pest these bellow code.

Abstraction Partern Demo :-

//Function as abstraction

var Do=function(){

console.log("Do is Called !!!");


var DoSomething=function(f){

console.log("Before Do function executed !!!");







console.log("After Do function executed !!!");


DoSomething (Do);

//End of Abstraction

Explanation :- In the above program we have declare two variable called as Do and DoSomething .Using this two variable I declare two functions.

So, What I am doing here is hiding the details of Do Function inside DoSomething Function. While calling I am only call DoSomething function which automatically get executed Do function.

Now what is it’s advantage ?

Advantage of this pattern is if you want to execute some block of code before and after the specific JavaScript function executed then it’s much helpful.

  1. Function to Build Module Pattern:-

In this pattern we are going to understand how we do encapsulation in JavaScript while write function in JavaScript.

Note :- It’s very useful pattern while doing JavaScript program, I recommended use this pattern while writing JavaScript code.

Let’s Jump in to Demo;

//Function to Build Module
var Do= function() {  //This is Global variable

var Job1 = function() {  //This is Local varibale.

console.log("Job1 is Called !!");


var Job2= function() {

console.log("Job2 is called !!");


return {


process2: Job2



var objDo= new Do();



//End Build Module

Explanation :-

In the above program I have declare a function using Do variable. Inside this function I have again declare another two function using local variable called as Job1 and Job2. Here I declare two function you can declare as many number as your requirement.

Hence this Job1 and Job2 are local under this Do function; so we cannot access this function outside of  Do function. Job1 and Job2 are only accessible inside the Do function only. Here Do is encapsulated both Job1 and Job2 function.

Remind Oops what saying about encapsulation ??

Hence here we achieve encapsulation as well.

Well; here it’s important to understand that how I am calling Job1 and Job2.

See above what I am doing is that I am returning job1 and Job2 function from Do function.

Always remember every function in Javascript always return some value by default.

To call the function we need to create an object of Do function and using this object I can call all the function define under Do.

Let’s discuss what is the advantages of this pattern?

  • Providing security over our code.
  • More clean code.
  • Avoid duplicate code and write the code specific to our page/view.

Based on my experience:-

Last point which I say above is “Avoid duplicate code and write the code specific to our page”; this is really useful if you are working as a web developer then you might understand this point very clearly.

In my working life what I see is that many programmer write the function but while giving name we are not sure that whether the name is used by someone else or not ??So while calling it’s get confuse that why our function not get executed rather executing someone else function; that due to same name of function.

So if we follow this above pattern we never ever face this problem.

 Hence I always recommended to all of you please follow this pattern.

  1. Function to avoid Global variable.

In this pattern we are going to see how to write a Global function also we see Immediately Invoked Function (IIF).

Let’s see this in demo;

var DoMain = function() {  //This is Global variable.

var Do= function() {

var Job1= function() {  //This is Local varibale.

console.log("Job1 is Called");


var Job2= function() {

console.log("Job2 is called");


return {


Process2: Job2



var objDo= new Do();

objDo.Process1 ();

objDo.Process2 ();



Explanation :-

If we analysis from first pattern program to this program then what I did in this is I write all the code inside one global variable called as DOMain and making it as a function.

So it’s easy to understand that I am just calling the DoMain() function and we get the same output as previous program.

So what you think nothing is new here right??

Yes….no…  🙂

Let see the new thing bellow :-

//Anonymous function or IIF function


var DoMain= function() {  //This is Global variable.

var Do= function() {

var Job1= function() {  //This is Local varibale.

console.log("Job1 is Called");


var Job2= function() {

console.log("Job2 is called");


return {


Process2: Job2



var objDo= new Do();

objDo.Process1 ();

objDo.Process2 ();




Explanation :-

If we analysis above example then we see that there is no variable I deified to store the function; rather I define a self-function which is similar to the anonymous function in C# language.

This type of Function basically called as Immediately invoked function (IIF) in Java script.

So while we writing this type of function then that function get executed immediately after DOM element loaded.

Note :- Basically this type of pattern used in case of developing plug in. We also see many plugin has this type pattern, if you see jquery.flowchart.Js plugin then you can get a clear picture that whole plugin developed using this pattern only.


So this all about our java script patterns and their purpose of uses.

Hope this is help full to you understanding all these patterns with simple example.

Above explanation based on my own experience and learning; so if you found anything mistake in that or any example not work then feel free to give you feedback.

Please say about what you feel about this article; which helps me to improve myself.

Thanks all.

Happy Coading.


X#(X-Sharp) another member in .Net Family.

X# is another programming language introduced by Microsoft. It’s now become another member of  .Net family like C# and F#.

Microsoft Core development team has developed this New language which run’s under dot net platform.

X# will going to lunch with new Upcoming Visual studio 2017. Visual studio 2017 going to be lunch on 7th march 2017.

For know more about VS2017RC; attend live lunch event of VS2017.

X# language has lots of new feature with the enhancement of .Net platform.

In this You will get new run time environment with some more advance features.

For know more about in details follow bellow link :-

X-Sharp Road Map.

Read More Details about X-Sharp.

Thanks for Reading.

Share your valuable comments.

To stay updated with new Technology follow me.

Powered by : #Share2Know #SuryanInfo 🙂