Resource Responses

Search Guest Response by Email:
Total 54 responses found.
.NET interview questions for 5+ years of experience - OOPS, C#, ASP.NET, .NET Fundamentals
Hai Saravanam,
Thanks for posting the questions. Below I am trying to provide the answers of these question. If anyone knows better answers please post them as they will help to all of us:
1. What is stack and heap?
Ans. Stack and Heap are the type to store the data. Stack is value type which stores the data directly while heap is reference type which stores the memory location and at those memory location, the actual data stores.
E.g. of Stack is int, float, char etc
E.g. of Heap is string, Array etc.

2. Why C# codes are converted to IL and why C++ codes are converted to machine code not IL?
Ans. Yes, the C# code first gets converted to the IL(CIL or MSIL) code because the C# is very high level language which cant communicate to the OS directly. The CSC(C# compiler) converts this very high level language to low level language called as IL and then JIT compiler finally convert this to machine language.
C++ is the middle level language so the C++ compiler can directly convert this to machine language which is finally understandable by the OS.

3. struct A
{
int a;
}
A.a.ToString();
What is the output?
Ans. 0 ( default for int)

4. How does the following code work? DataReader dr; for(DataRow r in dr) {}
And. DataReder is forward only read-only record-set.
When we write dr.Read(), it point to next record in the result set to read.

5. What are delegates? How will you add more than one method to a delegate?
Ans. Delegate is the function point which points to another method. We can execute other methods using delegate without concerning the class where the method exists.
To add more and one method, we can create multiple delegate and combine them. Delegate support + and - operators to add and subtract delegates.

6. Does the following code work?
class A {}
class B : A {}
A = new B();
Ans. Yes, this is a type of inheritance which works to assign the child class object to base class reference.
This is frequently used in interfaces.

7. Two classes: a, b
________ fun()
{
int I = 10;
if(I == 10) return new a();
else return new b();
}
What will be the return parameter?
Ans. object

8. interface A { int print(); }
interface B { int print(); }
class C : A, B
{
int print() { Print "Welcome"; }
}
How will you call B's print method?
Ans. When the parent interfaces have the same method and they are inherited to same class, we can call the interface method using external interface implementation.
In this we need to explicitly define the method of the interface as below:
class C : A, B
{
int A.print() { Print "Welcome A"; } // extended interface implementation
int B.print() { Print "Welcome B"; }// extended interface implementation
}

9. What is HTTPHandler?
Ans. HttpHandler is the utility to handle the requests coming in IIS. Handler are the way to filter the request of specific type so that other types of the request will not be entertained.
In case of ASP.Net, when the request comes through IIS, first it checks for the .aspx and if the requested page is html, the request will not come inside the IIS for the further processing.
HttpHandler handles the HTTP request and process it through HttpPipeline.

10. What is the purpose of HTTP, SOAP in web-service.
Ans. HTTP(Hyper Text Transfer Protocol) is the set of slandered for the web requests. SOAP ( Simple Object Access Protocol) is the message format which is used to send and receive data in the specific message format in case of services.
Web Service transmits and receive the data in form of Message and each message should have some format so that it will be understandable by the browser and getting the responses in the same format. SOAP defines the common format of the messages which is XML format and understandably by all the technologies(as XML is platform independent).

11. How many master pages does a page contain?
Ans. A single page can contain multiple master pages but they should be nested.

12. Is it possible to have nested master pages?
Ans. yes

13. What is difference between XAML and XML
Ans. XAML is the new declarative language used in the WPF and Silverlight application and can be used only in developing these type of applications while XML is the platform independent language and used mainly for the transferring of the data, carrying the data over the internet.

14. How will you pass a table returned by a SP as parameter to another SP.
Ans. We can declare a table variable(supported since Sql Server 2005) and then we need to create the column for that table variable and fill the data. After that we can pass the whole table in the stored procedure.

15. Where is the table name stored in SQL Server?
Ans. SYSOBJECTS contains all the database objects where we can search the table as below:
select * from sysobjects where xtype='U' will give all the table names and we can search our table by adding the additional criteria.

16. Write a query to get all the table names.
Ans. select * from sysobjects where xtype='U'

17. Consider a sub-query is used in more than one query in a SP. How will you achieve this? That is how will you write a query that reuses a sub-query?
Ans. We can use the loops inside the stored procedure and calculate the value each time when running the query. The other way could be the cursor.(Not sure about the question's expectations)

18. Table A has 5 rows and table B has 7 rows. How many rows does "Select * from A, B" return?
Ans."Select * from A, B" will return 35 rows(Cross join) where one record of the table A will be the cross product for the table B.

Author: Pawan Awasthi      Posted Date: 22 Jun 2015
Creating application using ASP.Net MVC 5 with Visual Studio 2013 (Code First Approach)
Hai Sathish,
You can try to create with the same steps. If you get any difficulties, let me know for any difficulties.

Author: Pawan Awasthi      Posted Date: 21 Jun 2015
Technical interview in Accenture
Hai Guys,
As per the continuation of the answers for the interview questions asked in Accenture, I am providing below the WCF questions answers:
1.why we are going for WCF major reason?
Ans. WCF = Web Service + Remoting + MSMQ + COM+
It means if you are creating a WCF service,you can use it in place of Web Service, Remoting, MSMQ or COM+ to interact with the server to serve the requests.
Due to that reason,we are going to WCF service.one WCF service can support and serve the request frommultipletype of clients.
2.why we are going for TCP binding?
Ans. TCP binding is used for the intranet type of requests. WCF service can serve and fulfill the request comes from TCP connection. To fulfill this, we need to create a TCP client which needs the TCP binding in it. While defining the Endpoint, we need to use the TCP binding.

3.Different between basic binding and ws*binding?
Ans. Basic HTTP binding is simply the Web Service which is not having the security features. WS* contains the security in it.The security can be of type Message Level or transport level.

4.what are instance modes available?
Ans.There are 3 Instance Modes are available in WCF service:
a. Per Call
b. Per Session
c. Singleton

5.what is throttling in WCF?
Ans. Throttling is a way to restrict the number of concurrent calls of the requests so that the service performance should not be degraded.
We can set the Maximum number of the concurrent connections, sessions and instances.

6.I am using Java project,we need to communication with that project?which binding is better.(Tell your answer clearly they shoot the questions from that.. :)
Ans. Basic Http or WSHttp binding can be used where SOAP will be used for the message format.

7.can able to control the browser request in WCF?
Ans. Using Throttling.

8.what are contract available?
Ans. There are 5 contracts available:
A. Service Contract
B. Operation Contract
C. Data Contract
D. Message Contract
E. Fault Contract

9.can overloading method in WCF?
Ans. Yes, Overloaded operations can be possible in WCF. We can use the Name attribute to distinguish the methods which are overloaded methods.

10.what is service contract? can you explain some other feature of that?
Ans. Service Contract mainly describes the operations which are used in the service or exposed by the service.
Service Operations are also provides the callback functions where the response can also be handled by the client.

Hope it will be helpful to you.
Author: Pawan Awasthi      Posted Date: 22 May 2014
Technical interview in Accenture
As per the continuation of the Answers for the Interview questions asked in Accenture, Below are the answers for the ASP.Net related questions:
1.What is state management?
Ans. Maintaining the state of the client through server is called as state management.
Now why state Management?
As we know that web is stateless. So if any thing happens to the server, our page gets flush-out and it cant maintain any data in it during the postback.
So to maintain the data, we need state management techniques. There are 2 types of state management techniques:
1. Client side- Cookies, Query string etc
2. Server Side- Session, Application, Cache,profile etc

2.What is Session?
Ans. Session is one of the server side state management techniques where the a unique client id gets generated for the first request from the client and maintained during the session with the server. Each tie the request sends to the server with the session id, the server checked if the session id is live,it respond back to h client with the the required details.
There are 2 types of sessions:
1. InProc session: When the session is stored in the process memory of the browser, the session is called as the Inproc session.In this session, when the browser is closed, the session data gets vanished.

2. OutProc Session: When the session is maintained out of the process memory of the browser, it is called as OutProc session. In this case, the session is maintained outside in a separate server so that if the browser is closed, then also session will be maintained.
There are 2 types of OutProc session data can be maintained:
A. In State server- This is separate server where the session data is maintained.
B. In SQL server- Session data can also be maintained in Sql Server database so that it will be available all the time and will be persistent.

3. Which one session manage type is better?
Ans. We cant say that which is better.Its all depends on the requirement and based on the requirements,we need to implement it.

4.what is cache and type?
Ans. Keeping frequently accessed data and maintaining it in separate storage is called as Cache. There are 3 types of caching:
1. Page output Caching
2. Data Caching
3. Fragment Caching

5.In your project page cache is use? and fragment cache is use? what cache you are using in your application any why ?
Ans. If we want to cache the user controls data, we can use fragment caching. it will not cache the whole page, instead it will cache only the user control data which is accessed frequently.

6.Data cache?
Ans. To cache the Data floating between the requests, can be cached using data caching.

7. Write piece of code for Data cache?
Ans. The definition for data caching is :
HttpRuntime.Cache.Insert(
/* key */
/* value */
/* dependencies */
/* absoluteExpiration */
/* slidingExpiration */
/* priority */
/* onRemoveCallback */
)
e.g. HttpRuntime.Cache.Insert("Key", Customers, null,Cache.NoAbsoluteExpiration, Cache.NoSlidingExpiration, CacheItemPriority.NotRemovable, null);

8.Did session use cookies and why? if cookies was disable in browser what happen?
Ans. yes, Session uses cookies to store the Session Identifier value. This value is used for each request which is sending from client to server.
But we can make the Cookie less sessions as well.
Hope it will be helpful to you.
Author: Pawan Awasthi      Posted Date: 21 May 2014
.NET Interview Questions for 3 years of experience people?
Hai Naveen,
Thanks for posting the questions which has asked in the interviews in various companies.These questions will be helpful for those who are preparing for the interview or going to attend the interviews in the near future.

Author: Pawan Awasthi      Posted Date: 29 Apr 2014
Techincal Interview In Changepond Technologies
Hai Rathimaran,
Thanks for posting the questions which has asked in the ChangePond technologies. These question will be helpful for those who are planning to go to the same company.
Thanks.
i will try to post the answer for the same in the future.

Author: Pawan Awasthi      Posted Date: 29 Apr 2014
Technical interview in Accenture
Hai All,
Please find below the answers for the interview questions which are asked in the Technical round in Accenture recently.
Below are the answers for the C#:

Technical Round

1.What is Garbage collection?
Ans. Garbage collection is an utility to claim the unused memory from the heap when the heap memory doesn't have the enough space to allocate the new object.
For more details, you can go through the below link:
Q.3
http://pawantechit.blogspot.se/2013/09/scenario-based-questions-in-net.html

2. What is delegate and type and explain?
Ans. Delegate is a type or we can say the type definition which is used to reference a function or method of the class.
the delegate can contain the return type and parameters similar to the actual function or method of the class.
For more details, go to the MSDN article:
http://msdn.microsoft.com/en-us/library/ms173171.aspx

3.Did you implemented delegate in project?
Ans. Yes, there are many situations where we implement delegates like when we have the event handler to be created on the fly, we can use the delegate.
e.g.
Button1.Click += delegate{ListBox1.items.Add(TextBox1.text)};
For more example, go through the MSDN link:
http://msdn.microsoft.com/en-us/library/ms173176.aspx

4.What is sealed class?
Ans. When the class provides full functionality, we can declare the class as sealed class. or if we don't want the class should not be inherited, we can declare the class as Sealed class. By making the class as Sealed, we can prevent the inheritance.
For more details,please go through the below link:
Q.11
http://pawantechit.blogspot.se/2014/04/2-yrs-experience-net-related-interview.html

5.What is void?
Ans. void is the return type which can be used with the class members like with the functions.
If the return type is void, the method won't return anything.

6.can void function have return value?
And. No, the void function doesn't have the return value.

7.can I use "return" variable inside the void methods? ( ans :we can use"return" key words only not with any datatype "return string_name")
Ans.Yes, we can use the return keyword without anything else if the return type is void.
private void Show()
{
return;
}

8.Did even have return type?
Ans. Didn't understand the question.

9.What is yield?
Ans. Yield is the new type which is introduced with the .net 2.0 or with Visual Studio 2005. Its like iterator which gives the value when its needed.
Below link will give more detailed explanation with the examples:
http://www.dotnetperls.com/yield
Continue...
Author: Pawan Awasthi      Posted Date: 29 Apr 2014
Technical interview in Accenture
Hai Rathimaran,
Thanks for sharing the interview experience for Accenture company. It will helpful for those who are preparing for the interviews or just planning to change the job.
I will try to answer them in the later.
Author: Pawan Awasthi      Posted Date: 29 Apr 2014
My experience of Interview in Horizon Softech
Hai Phagu,
Thanks for sharing your interview experience to all of us. Its great moments and we should be happy to share with all.
Also if you could have mentioned like the technologies related to your interview and the experience,it would have been better as may be some other time any other member could go to the same company and face similar type of queries.
Author: Pawan Awasthi      Posted Date: 29 Oct 2013
MVC3 (model view controller)- a new mvc framework with razor engine by microsoft
Hai Smily,
In MVC, we do validations at Model level. We use the concept called Data Annotation. This is the new concept which introduces with MVC and now you will see in the latest version of Visual Studio(2013 version) for all the the languages, we will do the same. They have full support for ASP.Net also in the new and latest version of .Net framework(4.5).
In the Data Annotation, we generally use the properties and put the validation on the properties so that throughout the application, wherever that property is used, it will be automatically validated and we don't need to validate it again and again as we were doing in older versions of visual studio.
Lets say we have EmpId which is mandatory field. So in the older versions of Visual Studio, we validate it by using the required filed validator or by any JavaScript code. Also we need to use the required field validator or the JavaScript code as many places as we use this field to be validated.
Now as per the latest concept of Data Annotation, we will validate at the model level. In model we define the properties with its validation attribute which will be decorated on the property(Decorator Design Pattern) So the property will be defines as below:

[Required]
public string EmpId{ get; set; }

Now it will validate the Empid wherever we will use this model.
Lets suppose we want that the EmployeeName should have maximum 20 characters and minimum 5 characters, we can validate it in the model class :

[MaxLength(20), MinLength(5)]
public string EmployeeName{ get; set; }

So by this way, we can validate all our field as well as the custom validator also possible. We can use RegEx here to be validated using the Regular expression etc.
Hope it will be helpful to you.
Author: Pawan Awasthi      Posted Date: 14 Oct 2013
DevExpress WinForms Controls - A comprehensive analysis
Hai Tony,
Excellent article for the DevExpress controls. These 3rd party controls are really helpful for some complex development.
Thanks a lot fr sharing it.
Author: Pawan Awasthi      Posted Date: 06 Sep 2013
Advanced interview questions for 6+ years of experience: Part 2
With lot of encouragement and support, I am posting the Part II of the questions and answers for 3-6 years experienced guys. These questions will be helpful for those who are preparing for the interview or attending the interviews. This will be helpful for the last minute preparation in quickest way.
If anyone has better answer, please reply to this post as that will be useful for all of us.

C# / ASP.net/ .Net framework / other .Net related questions:
1. What is the difference between IEnumerable and IQueryable?
Ans. IEnumerable and IQuerable are used to query data from database and collections. The IEnumerable is basically inherited from IQueryable, so it’s having all the features of the IQueryable in addition to its own features. Both have its own importance to query data and data manipulation
S.No IEnumerable IQueryable
1. Exists in System.Collections Namespace Exists in System.Linq Namespace
2. Can move to forward only in the collection. Can move to forward, backward or in between the items.
3. Best for collection like List, Array or in-memory collection Best for the collections which is out memory like services, remote databases etc
4. Suitable for LINQ to Objet and Linq to XML queries. Suitable for Linq to SQL queries
5. It doesn’t supports custom query, Lazy loading so it’s not good for paging scenarios. It supports custom query using CreateQuery and Execute methods. Also support lazy loading so good for the paging scenarios.
6. The extension methods which supports be IEnumrable takes the functional objects as the parameters. The extension methods which supports be IEnumrable takes the expression tree expressions as the parameters.

In the first example (By using the IEnumerable), the generated SQL is as below:

In the second example (By using the IQueryable), the generated SQL is as below:

We can see that by using the IQueryable, the performance will increase as it has the TOP clause in the query.
2. What is cross site scripting? (XSS)
Ans. Cross-site scripting is the way to attacks and insert the vulnerabilities in Web page. This attack is injected by client-side code. The script which is inject by the client can embed itself in response data. The response data which send back to the malicious user. The browser can’t recognize the scripts as it is responded from the trusted source.
The cross-site scripting attacks also work on the HTTP and HTTPS.
There are 2 ways to prevent the cross site scripting attack:
a. Constrain input- Validate the input length, type, formatting, range etc.
b. Encode output- Send the input data with encode e.g. Encode to HTML
To prevent the cross-site attack, we can set the below attributes in web.config file:


3. If I want to see my website similar in all the browsers then what I need to do for that?
Ans. If you want to see the website with the same look and feel then you need to write the common css style which should be same for all browsers. Actually every browser will not support every css elements so it is not possible to use the same css to support all the browsers. You need to write the common css elements in the file and then apply it across the website. Else you need to write the separate css file as per the browser.

4. If say 1 Lac users are using any particular website then what you will do to prevent crashing of server? Which care you will take at the time of coding?
Ans. There are the ways like we can have multiple servers to handle the requests from the users. In this, we can have the Web Gardening concept where we can have the multiple web servers and then one main server to handle the number of requests and switch the requests to other servers.
5. Why to use design patterns?
Ans. Design Pattern is the way to solve the recurring problems which occur during the designing of the applications. As the requirements increases, the projects becomes complex and due to the complexity, it’s difficult to maintain it.
With the help of design patterns, we can reduce the complexity and with the help of OOPs paradigm, we can make our applications more efficient in all the ways.
According to the GoF (Gang of Four) company, the Design Patterns can be classified to 3 ways:-
• Creational Design Pattern
• Behavioral Design Pattern
• Structural Design pattern

6. If I have a class C and two interfaces I1 and I2 and I have add method inside I1 and I2 then how to specify which one has to be called?
Ans. By using the explicit implement interface, we can implement the same method which is defined in both the interfaces.
e.g.

The implementation will be as below:

7. Garbage collection uses which type of algorithm? How it will find which object is unused?
Ans. Mark-And-Release is the algorithm which the garbage collection uses to reclaim the memory of the unreferenced objects which are no longer used.
The algorithm Mark-and-Release work in 2 steps:-
a. In the first steps, it marks all the accessible objects of the heap memory. This is called as mark phase.
b. In the second step, scan the heap and reclaim all the unmarked objects by the Garbage Collection algorithm. This step is called as sweep phase.
Below are the algorithm steps:

For the detailed description, follow the below link:
http://www.brpreiss.com/books/opus5/html/page424.html
8. What is the difference between out and ref?
Ans: Ref and Out are the parameters which are used in the methods. [ ref] and [out] both allow the called method to modify a parameter. The difference between them is what happens before you make the call.
• [ref] means that the parameter has a value on it before going into the function. The called function can read and or change the value any time. The parameter goes in, then comes out
• [out] means that the parameter has no official value before going into the function. The called function must initialize it. The parameter only goes out.
So the main difference between the ref and out parameters is that the out parameter doesn’t need to be initialized while the ref parameter must be initialized before passing to the function.
9. Is it possible to use more than one out parameter?
Ans. As we know that the method always returns a single value but by using the out parameter, we can return multiple values from the method or function.
In C# we can write the small code snippet which will describe to return the multiple values using the out parameters:

We can also use the struct which will contain the multiple values as the return:

There is another way to return multiple values like using Tuple class (newly introduces in .Net 4.0). The tuple class can return the object which can contain multiple values in it.

10. Is it possible to use .js files used under script will be in body and not in header? Why?
Ans. The .js file is used in header because first the .js file should be loaded to the application and then rest of the content should be load.
Cont..
Author: Pawan Awasthi      Posted Date: 18 Aug 2013
Advanced interview questions for 6+ years of experience: Part 2

With lot of encouragement and support, I am posting the Part II of the questions and answers for 3-6 years experienced guys. These questions will be helpful for those who are preparing for the interview or attending the interviews. This will be helpful for the last minute preparation in quickest way.
If anyone has better answer, please reply to this post as that will be useful for all of us.

C# / ASP.net/ .Net framework / other .Net related questions:
1. What is the difference between IEnumerable and IQueryable?
Ans. IEnumerable and IQuerable are used to query data from database and collections. The IEnumerable is basically inherited from IQueryable, so it’s having all the features of the IQueryable in addition to its own features. Both have its own importance to query data and data manipulation
S.No IEnumerable IQueryable
1. Exists in System.Collections Namespace Exists in System.Linq Namespace
2. Can move to forward only in the collection. Can move to forward, backward or in between the items.
3. Best for collection like List, Array or in-memory collection Best for the collections which is out memory like services, remote databases etc
4. Suitable for LINQ to Object and Linq to XML queries. Suitable for Linq to SQL queries
5. It doesn’t supports custom query, Lazy loading so it’s not good for paging scenarios. It supports custom query using CreateQuery and Execute methods. Also support lazy loading so good for the paging scenarios.
6. The extension methods which supports be IEnumrable takes the functional objects as the parameters. The extension methods which supports be IEnumrable takes the expression tree expressions as the parameters.

In the first example (By using the IEnumerable), the generated SQL is as below:

In the second example (By using the IQueryable), the generated SQL is as below:

We can see that by using the IQueryable, the performance will increase as it has the TOP clause in the query.
2. What is cross site scripting? (XSS)
Ans. Cross-site scripting is the way to attacks and insert the vulnerabilities in Web page. This attack is injected by client-side code. The script which is inject by the client can embed itself in response data. The response data which send back to the malicious user. The browser can’t recognize the scripts as it is responded from the trusted source.
The cross-site scripting attacks also work on the HTTP and HTTPS.
There are 2 ways to prevent the cross site scripting attack:
a. Constrain input- Validate the input length, type, formatting, range etc.
b. Encode output- Send the input data with encode e.g. Encode to HTML
To prevent the cross-site attack, we can set the below attributes in web.config file:


3. If I want to see my website similar in all the browsers then what I need to do for that?
Ans. If you want to see the website with the same look and feel then you need to write the common css style which should be same for all browsers. Actually every browser will not support every css elements so it is not possible to use the same css to support all the browsers. You need to write the common css elements in the file and then apply it across the website. Else you need to write the separate css file as per the browser.

4. If say 1 Lac users are using any particular website then what you will do to prevent crashing of server? Which care you will take at the time of coding?
Ans. There are the ways like we can have multiple servers to handle the requests from the users. In this, we can have the Web Gardening concept where we can have the multiple web servers and then one main server to handle the number of requests and switch the requests to other servers.
5. Why to use design patterns?
Ans. Design Pattern is the way to solve the recurring problems which occur during the designing of the applications. As the requirements increases, the projects becomes complex and due to the complexity, it’s difficult to maintain it.
With the help of design patterns, we can reduce the complexity and with the help of OOPs paradigm, we can make our applications more efficient in all the ways.
According to the GoF (Gang of Four) company, the Design Patterns can be classified to 3 ways:-
• Creational Design Pattern
• Behavioral Design Pattern
• Structural Design pattern

6. If I have a class C and two interfaces I1 and I2 and I have add method inside I1 and I2 then how to specify which one has to be called?
Ans. By using the explicit implement interface, we can implement the same method which is defined in both the interfaces.
e.g.

The implementation will be as below:

7. Garbage collection uses which type of algorithm? How it will find which object is unused?
Ans. Mark-And-Release is the algorithm which the garbage collection uses to reclaim the memory of the unreferenced objects which are no longer used.
The algorithm Mark-and-Release work in 2 steps:-
a. In the first steps, it marks all the accessible objects of the heap memory. This is called as mark phase.
b. In the second step, scan the heap and reclaim all the unmarked objects by the Garbage Collection algorithm. This step is called as sweep phase.
Below are the algorithm steps:

For the detailed description, follow the below link:
http://www.brpreiss.com/books/opus5/html/page424.html
8. What is the difference between out and ref?
Ans: Ref and Out are the parameters which are used in the methods. [ ref] and [out] both allow the called method to modify a parameter. The difference between them is what happens before you make the call.
• [ref] means that the parameter has a value on it before going into the function. The called function can read and or change the value any time. The parameter goes in, then comes out
• [out] means that the parameter has no official value before going into the function. The called function must initialize it. The parameter only goes out.
So the main difference between the ref and out parameters is that the out parameter doesn’t need to be initialized while the ref parameter must be initialized before passing to the function.
9. Is it possible to use more than one out parameter?
Ans. As we know that the method always returns a single value but by using the out parameter, we can return multiple values from the method or function.
In C# we can write the small code snippet which will describe to return the multiple values using the out parameters:

We can also use the struct which will contain the multiple values as the return:

There is another way to return multiple values like using Tuple class (newly introduces in .Net 4.0). The tuple class can return the object which can contain multiple values in it.

10. Is it possible to use .js files used under script will be in body and not in header? Why?
Ans. The .js file is used in header because first the .js file should be loaded to the application and then rest of the content should be load.
Cont..
Author: Pawan Awasthi      Posted Date: 18 Aug 2013
Advanced interview questions for 6+ years of experience: Part 2
Hai Prachi,
Excellent questions for 6+ years experience guys. These questions will definitely be helpful for those who are preparing for the interview and belongs to 5+ years category.I will try to provide the answers for these questions in the coming days...
guys...keep looking this thread for all your queries..
Author: Pawan Awasthi      Posted Date: 29 Jun 2013
Open Visual studio 2010 solution file in visual studio 2008 or visual studio 2005
Hai Prasad,
Excellent article related to conversion of projects solutions from one version to another version.
But i think you have missed an step here. After the conversion of solution file if you run the application, it will not run because you need to change the project file also.
If you right click the project file and then open in the notepad, it will still show the framework version which will not be support now as you made the changes in the solution file.
So with that we need to make the changes in the project file and use the relevant version like for Visual Studio 2010, make the changes to 4.0, for Visual Studio 2008, make it to 3.5 and so on.
Author: Pawan Awasthi      Posted Date: 09 Jun 2013
Widely asked in interviews: Delegate, Linq, Lambda Expn Create Extension Method & Expression Tree
Hai SSharma,
Good collection of the interview questions. These are really the good topics where now a days companies are concentrating more in the technical interview panels.
These topics will really be helpful for the people who are looking out for job and having 3+ yrs of experience.
Thanks for sharing these topics.
Author: Pawan Awasthi      Posted Date: 01 Jun 2013
Some Interview Questions for .Net technology
Cont…

21. Can we implement multiple inheritances by using interfaces in C#.net?
Ans. Yes, we can implement multiple inheritance using interfaces in C#. Multiple Inheritance doesn't support in C# because the runtime (CLR) can’t decide that from which base class the method to be inherited in case the same method signatures are there in both the base class.
e.g
class A
{
Public void Show()
{
Console.WriteLine(“Hello”);
}
}
Class B
{
Public void Show()
{
Console.WriteLine(“World”);
}
}
Class C: A, B
{
// Error will be thrown
}
This can be implemented by using Interfaces as:
Interface IA
{
void Show();
}
Class C: B,IA
{
Public void IA.Show()
{
Consolw.WriteLine(“Hello”);
}
}
Now when the object will be created, we can get the Show() method based on the Interface reference.

22. How a pointer stores address?
Ans. A Pointer is basically a variable which is used to store the address of another variable. It doesn't store the whole address; instead it stores only the first byte of the address. We can find the next bytes based on the size of the variable.
Lets say there is an integer which we want to keep through the pointer reference. The pointer will keep the first byte as the first address and then as the integer is of 4 bytes then we can add 3 more bytes to get the complete address.

23. Difference between Object Base and Object Oriented?
Ans. Object Based is the language which doesn't support Inheritance as it is the abstract member and not support the class objects. E.g. VB 6.0
Object oriented language supports the inheritance and polymorphism concepts because of the class and objects. E.g. .Net, Java

24. Main Difference between Method and function?
Ans. A function is the code which is called by its name. We can pass the data to it for the operations (i.e. passing parameter) and can return data or value. The parameters which are passed to the functions are explicit.
A method is the code which is also called by name but it is always associated with an object. It is similar to the function except it is implicitly passes the parameters object which it was called. Also operations can be performed by passing the parameters which are contained in the class. So we can pass the instance of the class in the method.

25. What is the difference between a struct and a class in C#?
Ans. There are many differences between the class and struct:
• Structs are value types while the class is reference type.
• As the Structs are value type and all value types are inherit from the class System.ValueType while the class is reference type and all reference types are inherited from Sysem.Object.
• When the value is assigned to the struct, it directly creates a copy of the value while the class object is kept as the reference and not the value.
• We can perform the operations like Boxing and unboxing to convert the struct type to class object.
• Initialization is not support Instance field declarations for a struct are not permitted to include variable initializes.
• Struct support parameterized constructor while class can support parameter less constructors.
• We can’t declare destructor for the struct while we can create the destructor for the class.

26. If you are required to call a non-static method in static method then how will you do this?
Ans. Directly we can’t call the non-static method inside the static method. For this, you can create the object of the method and then you can call the method by the class name as:
public class MyClass
{
public void MyMethod()
{
}

public static void MyStaticMethod()
{
MyClass objClass = new MyClass();
objClass.MyMethod();
}
}


27. If you want to restrict user to make only one object in the entire application usage how will you achieve this?
Ans. We can use the Singleton class object which will allow maximum one instance. In this class object,
public sealed class DemoClass
{
public static readonly _instance = new DemoClass();
public static readonly Instance
{
get
{
return _instance;
}
}
DemoClass()
{
}
}

28. What's difference between Association, Aggregation and Inheritance relationships?
Ans. The Association, Aggregation and Inheritance are the concepts of the OOPs which can be associated with the class objects.
When the objects are having the common structure or if they are similar then we can associate them using the Association. So the relationship between the common structure or common behavior is called as Association.
e.g. Employee ??Manager Here Manager is also an employee

While the Aggregation is “a part of” relationship.
e.g. Student is “a part of” college.
Inheritance is the concept where one class objects can be inherited to another class. It has “is a” and “has a” relationships. The derived class can inherit the parent class behaviors and the characteristics.
Example:
A specialized student can be inherited from the student class.

29. How can we achieve inheritance in VB.NET?
Ans. In Vb.Net Inherits keyword is used to inherit the base class members to the derived classes.
Public Class BaseClass
Public val1 As Integer = 1
Public Function val() As Integer
Return val1
End Function
End Class

Public Class DerivedClass
Inherits BaseClass
Public val As Integer = 10
Public Function add() As Integer
Return val + val1
End Function
End Class

30. What are abstract classes?
Ans. When the class doesn't provide the full functionality then we can declare the class as abstract class.
Collection of the Abstract (Incomplete) and Concrete (complete) methods is called as the Abstract class. If there is at least one abstract method in a class, the class must be abstract class.
When there is the similar behavior, we can use the abstract class.
e.g. We want to calculate the area of few component. As this is not generic to the application. We have only few component- like Circle, Ellipse, parabola, Hyperbola, Triangle etc.
So we can create an abstract class and implement it like below:
public abstract class MyAbstractClass
{
// some other concrete members
public abstract void Area();// abstract member
}
Now in the child class, let’s say i have a circle class and want to calculate the area of the circle:
pyblic class Cicle: MyAbstractClass
{
public override void Area()
{
// calculate the area of the circle
}

}
In the similar fashion, we can calculate the area of other shapes.

Cont…
Author: Pawan Awasthi      Posted Date: 01 Jun 2013
Advanced technical interview questions for 6+ years of experience.
Hai Baskar,
yes, you are right. Now a days companies are asking about the scenarios based questions if you are having 3+ yrs experience.
I will try to post such questions with the answer so that people can get benefit of it and they can respond to those answers in the interviews.
Author: Pawan Awasthi      Posted Date: 28 May 2013
How to show gridview row details in tooltip using jquery
Hey,
Thanks for posting such a nice article. It will relly be helpful for one of my requirements in the web application development.
Thanks a lot.
Author: Pawan Awasthi      Posted Date: 27 May 2013
Some Interview Questions for .Net technology
11. Define Modularity?
Ans. Modularity in OOPs means the design of the program should be in such a way so that it can be broken in to pieces or modules and then each module can build separately. It leads to the less interdependence between the modules and the whole program can be structured and completed in the perfect manner. Many people can work separate modules and all modules can be combines at the end to get the full program.

12. What is meant by Persistence?
Ans. The way through which the data is active in different executions of the program during the execution of the program. By using the Persistence feature the execution mode data can be kept alive during the multiple execution of the program.

13. What is friend function?
Ans. A special type of functions which can access the private data of a class. This is the loophole in C++ programming. These functions defines outside of the class and can call the other class members.
For more details, follow the below link:
http://www.fredosaurus.com/notes-cpp/oop-condestructors/friendfunctions.html

14. What is a virtual function?
Ans. Virtual functions are the special type of function which has the capability to redefine in the child classes and they can force the runtime to get the overridden method of the child class rather than calling to the base class method. These methods can be redefined with the same structure in the child classes.
e.g.
class Parent
{
public virtual void Show()
{
Console.WriteLine("Hello Parent");
}
}

class Child : Parent
{
public override void Show()
{
Console.WriteLine("Hello Child");
}
}
Now we can create the object of the child class and call its method. By default it will take the child class definition to be executed as:
class Program
{
static void Main()
{
Child c= new Child();
c.Show();
}
}


15. What is a ternary operator?
Ans. The ternary operator is used for testing a condition. It mainly compares two values. In result it gets the third value which depends upon the result of the comparison. This is the shortcut of if..else statements.
e.g.
int result= 0;
if(a==10)
{
Result = 10;
}
Else
{
Result= 20;
}
Now the same we can write in a single line using ternary operator as:
int result = (a ==10)?10:20;

16. What is exception handling?
Ans. Exception I the runtime condition which stops execution of a program abnormally. To support exception, C# provides the structured exception handlers. .Net Provides Try..Catch..Finally keywords for handling exceptions.
Exception is the base class for all the exceptions. There are 2 types of exceptions-
• Runtime Exceptions- System Defined
• Application Exceptions- User Defined
When an exception is expected, we need to write the code under Try block. Try must be followed with the Catch or Catch with Finally or Try ..Catch and Finally.
One and Only one Finally block can exists with Try and Catch.
Finally Block always executes whether the Exception occurred or not.

17. What are the various types of constructors?
Ans. There are 3 types of constructor:
• Default constructor
• Parameterized constructor
• Copy Constrictor

18. What is a copy constructor?
Ans. This concept is not in .net. It’s in C++ and in Java. Mainly the Copy constructor is used when we have an object and wants to copy the object from existing objects. Here in C#, we need to write the method to copy all the objects from the existing object.
For more details follow the below link:
http://msdn.microsoft.com/en-us/library/ms173116(v=vs.80).aspx

19. What is Access Modifier in OOPS?
Ans. Access Specifies or Access Modifiers defines the accessibility with in the class and methods. In C#, there are 5 types of Access Modifiers:
• Public – Accessed by any subclass by object instance inside or outside of the assembly.
• Protected- Accessed inside as well as to the child class. Scope it limited to the child class.
• Private- Accessible only in the current class where defines. Not accessible to outside of the current class.
• Internal- Accessible inside the class as well as outside of the class by instance but not outside of the assembly.
• Protected internal- Accessible inside the class as well as outside the class and the class derived from the current class. But the scope is limited to the current assembly.

20. What is Compile Time Polymorphism in OOPS?
Ans. When the runtime (CLR) find the behavior of class members at the compilation of the program, it is called as the Classical polymorphism or Compile Time Polymorphism or Overloading.in this the method name is same but there prototypes (parameters) are different and it is implemented in the same class.
e.g.
Public class MyBaseClass
{
Public virtual void Show(string message)
{
Console.WriteLine(“Your message is : ”+ message);
}
}
Public class MyChildClass: MyBaseClass
{
public override void Show(string message)
{
Console.WriteLine(“Your new message is : ”+ message);
}
}

Cont…
Author: Pawan Awasthi      Posted Date: 26 May 2013
Advanced technical interview questions for 6+ years of experience.
Hai Prachi,
Thanks for sharing such a nice collection for the questions. These questions will definitely be helpful for those who are preparing for the interview or have plan in preparation. As these are the small and tricky questions so it will be helpful in cracking the interviews for 5+ years experience guys and they can prepare in advance for these type of questions.
I will try to post the answers for these questions in the coming days..Guys, please keep watching this section for the answers in very few days..
Author: Pawan Awasthi      Posted Date: 25 May 2013
United Health Group Technical Interview for 4+ years experience in dotnet
Below I am trying to provide the answers of the remaining questions.
8. What are delegates and events. What is the default handler in C#.
Ans. A Delegate is an object, which points to another method in the application. Delegate holds, name of the method, arguments of the method (if any) and the return type of the method.
See the below points regarding the Delegate:-
• delegate keyword is sealed type in System. Multicast namespace.
• Delegate works like a function pointer in C language.
• Delegate holds the address of the function.
• Delegate hides the actual information which is written inside the method definition.
• A delegate can hold address of a single function as well as the address of multiple functions.
• There are 2 types of delegate- Single-cast delegate (hold single function) and Multicast delegate(hold multiple functions).
• Addition and subtraction are allowed for the delegates but NOT multiplication and division. It means, we can add delegates, subtract delegates etc.
e.g. To create a single cast delegate, first we can create a class with a method as:
public class DelegateDemo
{
public void Show(string msg)
{
Console.WriteLine(msg);
}
}
Now we can call the method Show using the delegate as:
public delegate void MyDelegate(string message); //declare delegate
now we need to create the object of the delegate with the address of the method as:
DelegateDemo obj = new DelegateDemo();//class object
MyDelegate md= new MyDelegate(obj.Show(“Hello World!!”));
md(); // call the delegate
We can create the events and event handler by using delegate with the below syntax:
public delegate void textChangedEventHandler(Object sender, TextEventArgs e);
This event handler will be used to handle the textbox text changed event.
We can get more details about the delegate and events from the below link:
http://msdn.microsoft.com/en-in/library/orm-9780596521066-01-17.aspx


9. What is polymorphism? What are the types of polymorphism and how they are implemented?
Ans. Polymorphism is to use the same function in many forms. The polymorphism is of 2 types-
a. Classical polymorphism (Overloading)
b. AdHoc polymorphism (Overriding)
When the runtime (CLR) find the behavior of class members at the runtime of the program, it is called as the AdHoc polymorphism or Overriding.in this the method name is same but they are implemented in the different class. We use virtual keyword in the base class method to be overrides in the child class using the override keyword.
e.g.
public class MyClass
{
Public int Add(int a, int b)
{
Return a+b;
}
Public int Add(int a, int b, int c)
{
Return a+b+c;
}
}
When the runtime (CLR) find the behavior of class members at the compilation of the program, it is called as the Classical polymorphism or Overloading.in this the method name is same but there prototypes (parameters) are different and it is implemented in the same class.
e.g.
Public class MyBaseClass
{
Public virtual void Show(string message)
{
Console.WriteLine(“Your message is : ”+ message);
}
}
Public class MyChildClass: MyBaseClass
{
public override void Show(string message)
{
Console.WriteLine(“Your new message is : ”+ message);
}
}

10. Difference between exe and dll.
Ans. Exe(Executable) is the executable file which can be run standalone without support of any other file. It contains the self-executable information so it doesn’t need any external file or program to execute.
Dll(Dynamic Link Library) is the file which is not self-executable. It needs to be executed inside some other file. It is used to support the other dll’s or exe files.
11.Types of assemblies
Ans. In .net, there are mainly 3 types of assemblies:
• Private Assembly
• Shared Assemblies
• Satellite Assemblies
12. Is public static void Main() method available in console based applications/Windows/Web applications?
Ans. public static void Main() method is available in the Console application where this is the starting point of the console to be executed. The execution of the program starts from the Main() method.

13.A dll in GAC and a dll on a network which one is secure and why?
Ans. A dll in GAC is more secure and the most important is that in GAC, we can keep multiple versions of the dll which are having the same name while in the network we can’t keep the same name with multiple version files. So whenever there is the requirement to share the dll’s, always keep it in GAC instead of in a sharing folder in the network.
WPF
1. Difference between MVVM pattern and n-tier architecture.
Ans. MVVM(Model View View-Model) is one of the latest patters which is having the 3 layers-Model, View and View-Model
This is the latest design pattern to develop the application mainly in Silverlight applications or WPF application. The main advantages of using this Design patterns is that it’s layers are totally independent to each other. The Model doesn’t know about the View, View doesn’t now about the View-Model and Vice Versa.
So the layers are not tightly binded to each other. If we modify in one of the layer, we need not to modify the other layers. Application developed in MVVM model, is testable without the View.
In Case of3-tier application, all the 3 layers (Application Layer, Business Logic layer and Data Access layer) are tightly bounded to each other. So if there are any changes in any of the layer, we need to modify the other layers accordingly. All the layers are tightly bounded and dependent to each other so maintainability is difficult. We can’t test the application without the UI.
2. Advantages of using MVVM pattern
• The actual data is not stored in the View as View is only for the presentation of the data.
• The code is easily testable without using the View. The maintenance is quite easy as the layers are not dependent to each other.
• Layers are loosely coupled so maintenance is easy.
3. Have you used PRISM in your project?
Ans. No.
Hope it will be helpful to all the members.
Author: Pawan Awasthi      Posted Date: 25 May 2013
United Health Group Technical Interview for 4+ years experience in dotnet
Thanks for posting such a nice question with the answer for 4+ years experience.
Now a days there are the requirements in UHG and i hope most of the folks are preparing for attending the interviews. Such kind of initiatives will definitely take them to crack the interviews.
Thanks a lot. For the remaining questions which are unanswered i will try to post the answers.
Author: Pawan Awasthi      Posted Date: 25 May 2013
Some Interview Questions for .Net technology
Hi Rani Priya,
Thanks for posting good 70+ questions of OOPs. These questions will really help to those who are preparing the OOPs concepts in the last minute before going to attend the interview.
Below I am trying to provide the answers to each of the question.
The system is not allowing to post more text under one response so I have split the question in to multiple sections and posting them.

.Net questions with OOPS

1. What is Object Oriented Programming?
Ans. Based on the Style of programming, languages can be divided in to 3 types:-
a. Procedural Languages (e.g. ALGOL-1954)
b. Structural Languages (e.g. C – 1970 , BASIC, COBOL)
c. Object Oriented Languages (e.g. C++, Java, C#, VB.Net)
When a language follows the following features or rules then it is called as Object Oriented Language-
• Encapsulation
• Abstraction
• Polymorphism
• Inheritance
Including this, the language should support the Class and Object feature also.

2. What's a Class?
Ans. Class is a Logical representation which provides the structure for objects. As per the .Net Technology, a class is the collection of –
• Fields
• Properties
• Methods
• Events
Field- Private data of a class I called as field.
Property- It defines shape of an object.
Method- “What an object can do?” is defined by method. It provides the way to interact with the object’s state.
Event- Action on the object is called as Event.

3. What's a Object?
Ans. Instance of the class is called as object. By default event class inherits from System.Object class
By default , a class have 4 methods-
GetType()- Returns the type of Class Name
Equals()- To copare the objects
GetHashCode()- Return starting address in the heap memory
ToString()- to convert to string.

4. What's the relation between Classes and Objects?
Ans. Instance of a class is called as object. Class is the blueprint and doesn’t contain any memory. Object contains memory.
Class Object
1. Logical Physical
2. Occupy less memory Occupy more memory
3. No Life time Have Life time- Birth Time(Constructor) and Death Time(Destructor)
MyClass objClass = new MyClass();
Here objClass is the object of the Class MyClass.

5. What are different properties provided by Object-oriented systems?
Ans. Object Orient System is based on 4 Pillars which are backbone of any system to be Object oriented. These Pillars are
• Encapsulation
• Abstraction
• Polymorphism
• Inheritance

6. Can you explain different properties of Object Oriented Systems?
Ans. Below are the explanation of each of the Object orient Systems:
1. Encapsulation – It is the concept of Data Hiding. It hides the unnecessary details of implementation from the class object. By this rul of OOPs, the object’s internal data should not be accessible directly through the object instances. To implement this concept, we use the Access Specifiers(Public, private, Protected etc).
2. Abstraction- Abstraction is the behavior to get the required functionality in the child class. So we don’t matter whatever is written in the base class. We only need to force the child class to implement my required functionality.
Abstract keyword is used to get the abstraction behavior.
3. Polymorphism- Using the same method in multiple forms is called as Polymorphism. In the Polymorphism, the method name is same but their prototype can be different.
E.g. Add(), Add(int a, int b),Add(int a, int b, int c)
4. Inheritance- Inheriting the parent class behavior to the child class is called as inheritance. Also Deriving the features of the one class(base class) to the other class (child class) is also called as inheritance. Inheritance leads to code reusability, and saves memory, reduce the complexity and increase the easy maintainability of the code. There are 5 types of inheritance:-
• Single Inheritance
• Multilevel Inheritance
• Multiple Inheritance
• Hierarchical Inheritance
• Hybrid Inheritance

7. What is Polymorphism?
Ans. Polymorphism is to use the same function in many forms. The polymorphism is of 2 types-
a. Classical polymorphism (Overloading)
b. AdHoc polymorphism (Overriding)
When the runtime (CLR) find the behavior of class members at the runtime of the program, it is called as the AdHoc polymorphism or Overriding.in this the method name is same but they are implemented in the different class. We use virtual keyword in the base class method to be overrides in the child class using the override keyword.
e.g.
public class MyClass
{
Public int Add(int a, int b)
{
Return a+b;
}
Public int Add(int a, int b, int c)
{
Return a+b+c;
}
}
When the runtime (CLR) find the behavior of class members at the compilation of the program, it is called as the Classical polymorphism or Overloading.in this the method name is same but there prototypes (parameters) are different and it is implemented in the same class.
e.g.
Public class MyBaseClass
{
Public virtual void Show(string message)
{
Console.WriteLine(“Your message is : ”+ message);
}
}
Public class MyChildClass: MyBaseClass
{
public override void Show(string message)
{
Console.WriteLine(“Your new message is : ”+ message);
}
}


8. What is meant by Binding?
Ans. Binding is the way by which the class objects gets associated.
There are 2 types of bindings:-
• Early Binding- Also called as Static Binding
• Late Binding - Also called as Dynamic Binding

9. What is meant by static binding?
Static binding is a binding type where the association of the class object is done during the compilation of the program. It means while compilation of the application, the run-time (CLR) finds the behavior of such class objects. For example- Overloading the example for the static binding where the methods which are overloaded are defined and associated during the compilation.
This binding is also called as Early binding. It is good in such scenarios where the objects are heavy so if there is any error, it will show during the compilation and can be fixed before running the application.

10. What is meant by Dynamic binding?
Dynamic binding is a binding where the class object gets associated in runtime of the application based on the preferences and requirements. If an object is needed then only it will be associated else it will not be included in the run-time. Its good in such scenarios where we have very less dependencies between the object as while loading, it should load only those objects which are necessary and not load the other objects. This binding is also called as Late Binding. So the object is created only when required is the main concept of the late binding..
Cont…
Author: Pawan Awasthi      Posted Date: 25 May 2013
Some Interview Questions for .Net technology
Hai Rani,
Thanks for posting 70+ questions related to the OOPs concept. These questions will definitely helpful for those who want to refresh the OOPs concept in less time. They can check their knowledge by these questions.
Author: Pawan Awasthi      Posted Date: 24 May 2013
Interview Questions for 3-6 years experienced .Net professional
Cont…

61. What is Prism?
A. Prism is the framework or the set of guidelines which is used to develop the WPF desktop application as well as the Silverlight Rich Internet applications. So it’s a kind of Design pattern to Develop the XMAL based application. It also used to develop the Windows 7 applications. Prism mainly helps to design the loosely coupled components which can be easily integrated with the other components of the overall application. Prism mainly used to build the composite applications which need various other components to be integrated.
Prism mainly guides of creating the applications using the Model-View-ViewModel (MVVM) model, Managed Extensibility Framework (MEF), and navigation in the application.
To use the Prism framework, we need to use their library called as Prism Library. So prism Library is the inbuilt set of components which can be used in developing the WPF and Silverlight applications.
You can go through the below link for more details and the use of the components of the Prism framework:
http://msdn.microsoft.com/en-us/library/ff648465.aspx


62. Dependency Injection, Event Aggregator.
A. For the details about the dependency injection, you can follow the below link:
http://wpftutorial.net/ReferenceArchitecture.html
EventAggregator : It is the utility service which contains the events and allows the decouple the publisher and subscriber so that they can be buildup independently. Decouple is primarily useful when a new module needs to be added or removed or modified. The new module can be added as per the event fired and defined in the shell.
For more details about the Event Aggregator, you can follow the below link:
http://msdn.microsoft.com/en-us/library/ff921122(v=pandp.20).aspx

63. Shell, Bootstrapper and Region Managers
A. Bootstrapper:- An utility in WPF engine which is mainly responsible for the initialization of the application by using the composite application library. By using the bootstrapper we can find out how the components of the application are wired up in the composite application library. The bootstrapper responsibility to create the Shell or main window. Composite application library has the default abstract class UnityBootstrapper which actually handles the initialization.
You can go through the below link for more details about the bootstrapper:
http://msdn.microsoft.com/en-us/library/ff921139(v=pandp.20).aspx
Region and Region Managers: This is concept of Prism framework. We define the region through XAML code and once a region is defined, automatically it will be registered with the RegionManager. Actually the Bootstrapper registers a service called the RegionManager at run time. RegionManager is a dictionary where the key is name of the region. The value of the key is the reference of the IRegion interface. RegionAdapter is used to create the instance reference of the IRegion interface.
You can go through the below link for more details about the Region and Region Manager:
http://msdn.microsoft.com/en-us/magazine/cc785479.aspx#id0090091

64. What are MEF and Unity?
A. The MEF (Managed Extensibility Framework) is the new concept in .net 4.0. It is used to create the lightweight and extensible applications to create Managed Extensibility Framework. It is not only allows the extension but also reused within the application. Extension can be easily encapsulating the code using the MEF.
For more details, you can go through the below link:
http://msdn.microsoft.com/en-us/library/dd460648.aspx

65. How to navigate to another page?
A. There is a class NavigationService which can be used for navigation of the WPF window:
this.NavigationService.GoForward();
//or
this.NavigationService.Navigate("MysecondPage.xaml")

Hope the answer will be helpful to all the members.
Author: Pawan Awasthi      Posted Date: 17 Mar 2013
Interview Questions for 3-6 years experienced .Net professional
Cont…

51. What is the difference between Transport and Message Security mode?
A. WCF supports 2 types of security- Transport Level Security and Message Level Security
Transport Level Security- In this type of security, we make the transport channel as secure so that the data flows in that channel will be automatically secured. For HTTP channel, we use the client certificate for the security of the web address. SSL is used for the HTTP channel security. As we don’t need to secure each of the messages which are floating between the client and the service, the speed is faster as direct message is going to the client from the service.
Message level security- This type of security in WCF is used where we don’t have the fixed transport medium and we need to secure each message which is floating between the server and the client. In this type of security we use certain algorithms for making the message as secure message. We use some extra bits and send with the message. We also use some encryption techniques like SHA1 or MD5 which make the proper security for our message. As each message needs to be secured, this type of security makes some delay in the process of sending and receiving the messages.

52. How to configure WCF security to support Windows authentication?
A. To support the WCF security in Windows Authentication, we need to add the ClientCredetialType attribute to “Windows” under the security tab element:
transport clientCredentialType="Windows"

53. How to use Fault Contract?
A. Fault Contract is mainly used for viewing and displaying the errors which occurred in the service. So it basically documents the error and the error message can be shown to the user in the understandable way. We can’t use here the try….catch block for the error handling because the try…catch is the technology specific (.Net Technology). So we use the Fault contract for the error handling.
e.g. To use the Fault contract, we can simply write like the below:
public int Add(int number1,int number2)
{
// write some implementation
throw new FaultException (“Error while adding data..”);
}
Here the fault Exception method is the inbuilt method which will throw the exception and display the message . We can use the custom class so that the message can be customized and the customized message can be sent to the client.
So we can creeat a clss like:
Public Class CustomException()
{
public int ID{get;set;}
public string Message{get;set;}

public string Type{get;set;}
}
Now this custom type we ca use with the Operation Contract as:
[ServiceContract]
Public interface IMyInterface
{
[OperationContract]
[FaultContract(typeOf(CustomException))]
Int Add(int num1,int num2);
}
Now while implementation of the Add method, we can assign the class properties.

WPF

54. Diff between XML and XAML.
A. XAML is the declarative XML based language which is used to define the objects and properties. XAML document is loaded by XAML parser. So XAML Parser initiates the objects and set those properties. XAML is mainly used in creating the objects in WPF and Silverlight applications.
For more detailed explanation, you can go through the below link:
http://www.differencebetween.net/technology/software-technology/difference-between-xml-and-xaml/

55. Stack Panel and Wrap Panel.
A. StackPanel is one of layout control in WPF. We can place the child controls inside the stack panel either horizontally or vertically. So it provides two types of orientations- Horizontal Orientation and Vertical orientation.
You can go through the below link for more detailed explanation and the code snippet:
http://wpftutorial.net/StackPanel.html

Wrap panel is another layout control which is similar to the StackPanel. Wrap panel not only keep the control in horizontal and vertical orientation but also wrap them in to new line if there is no space. Here also the orientation can be set as Horizontal or Vertical. Its main use is to arrange the tabs in the tab control, menu control or in toolbar items.
You can go through the below link for more details:
http://wpftutorial.net/WrapPanel.html

56. Hierarchical Data Template.
A. Hierarchical Data Template is a type of data template which is used to bind the controls which supports HeaderedItemsControl, like TreeViewItem or MenuItem
We can bind those controls items using the Hierarchical Data Template. It displayed the data in to Hierarchical structure in the tree structure. It could be in the left to right or top to bottom.
You can go through the below link for more details:
http://msdn.microsoft.com/en-us/library/system.windows.hierarchicaldatatemplate.aspx

57. Virtualization.
A. This is the feature in WPF which increases the efficiency of the programs when there are the large data objects. If the WPF ItemsControl is bound with the large collection data source object and we enabled the virtualization, then the controls will show only the data which is in the visual container for those items which are visible currently. This visual data is only the small part of the large data object. Now when the user will scroll down or up, the rest of the data will be visible and previous data will be hidden again. So this is increase the efficiency of the program from the UI prospective.

58. Events and Routed Events.
A. Routed event is special type of event which can invoke and handle multiple events from different objects rather than the event which is coming from one object. So it generally handles the object from the element tree. So whatever the elements inside the element tree and if they generate the event-may be multiple events, the routed event is capable of handling those events.
The routed event can be invoked in both the directions but in general it comes from the source element and then bubbled up in the element tree until the root element.

59. Bubbling and Tunneling.
A. Bubbling: When the events are raised form the innermost element in the visual tree and comes up towards the root element, is called as bubbling.
Tunneling: It is the opposite process of Bubbling where the events fired by the root element goes down towards the last child element control.
Please go through the below link for more details:
http://www.dotnetspider.com/forum/130497-event-bubbling-event-tunneling.aspx

60. Resource Dictionary, Static Resources and Dynamic Resources.
A. Static and Dynamic resources are used for binding the resources to the control objects.
The main difference between StaticResource and DynamicResource is that how the resource is retrieved elements. If the resource is StaticResource, it will be retrieved only once by the element whoe is referencing it and it will be used for all the resources. While the DynamicResource gets its value each time they reference to the objects. So StaticResource is faster than the DynamicResource , because StaticResource needs to get the value only once while the DynamicResource needs each time to get it.

Cont…
Author: Pawan Awasthi      Posted Date: 15 Mar 2013
Interview Questions for 3-6 years experienced .Net professional
Cont...

41. What does @ and @@ suffixed by property names specify?
A. @- This is used for the variable declaration
e.g. @name varchar2(50)
@@- This is used for the Global variable declaration
e.g. @@Error=0

42. Self-join queries.
A. Self-Join is a type of join which is used to join the same table by creating the second instance of the same table. So we join 2 instances of the same table in case of self-join. This type of join is used when there is the requirement to get the referenced data which is available in the same table.
e.g. A table contains EmpId, Ename and ManagerId
As the manager id is also an employee id. Now if we want that who is the manager of which employee. In this situation, we need to create the instance of the same table and get the required data as:
SELECT EMPID, ENAME, ENAME AS [MANAGER NAME]
FROM EMP E1, EMP E2
WHERE E1.EMPID= E2.MANAGERID

43. Types of Index.
A. Indexes are one the database objects which is used to improve the performance of the database queries. it reduces the table scan while retrieving the data from the database and the search gets fast-
There are 2 types of indexes used in the SQL server:
a. Clustered index
b. Non clustered index
There are 3 more types of index but those comes under the above two-
a. unique index
b. Composite Index
c. XML Index-added in SQL Server 2005
The index basically works on searching like binary tree where the root value is the finding value and it will be compared with the partitioned value of the tree.

44. Difference between Primary key, Unique key and Candidate key?
A. Primary Key- It is a key to make the unique identification of the row in a table. It doesn't allow null values in the primary key column. We can create the look-up columns based on the primary key. One table allows maximum of 1 primary key and in 1 table, we can create the primary key column by using 16 columns. Due to one of the normalization rule,

45. What is the default value for Date type. What are Min and Max values for Date in 2008.
A. The default value of Date is CURRENT_TIMESTAMP
Below are the new date and time values in Sql Server 2008:
In SQL Server 2008:
1. DateTime2
Min Value: 0001-01-01 00:00:00.0000000
Max Value: 9999-12-31 23:59:59.9999999
2. Date
Min Value: 0001-01-01
Max Value: 9999-12-31

You can go through the below link for couple of work around:
http://dhaneenja.blogspot.in/2008/06/minimum-year-value-in-sql-server.html

WCF

46. What is WCF also known as?
A. WCF (Windows Communication Foundation) is also know an Indigo by its code name.

47. Difference between WCF and Web Services?
A. Below are the main differences between the WCF and Web Service:
Web Service:
a. Can be hosted in IIS only
b. Only two types of operations affects- One-Way, Request-Response
c. To serialize the data use System.Xml.Serialization
d. To encode the data use- XML 1.0, MTOM, DIME, Custom
WCF service:
a. Can be hosted in IIS, Self Hosting, WAS, Windows Services etc
b. Three types of operations affects- One-Way, Request-Response and Duplex
c. To serialize the data use System.Runtimel.Serialization
d. To encode the data use- XML 1.0, MTOM,Binary, Custom
e. WCF Service can be accessed through HTTP, TCP, Named pipes, MSMQ,P2P etc.

48. What are Endpoints?
A. The collection of Address, Binding and Contract is called as End Point. In Sort,
EndPoint = A+B+C
Address (Where)- it means where the service is hosted. URL of the service shows the address.
Binding (How)- How to connect to the service, is defined by the Binding. It basically has the definition of the communication channel to communicate to the WCF service
Contract (what)- It means what the service contains for the client. What all the methods are implemented in the WCF service is implemented in the Contract.

49. What are Behavior and Bindings?
A. Binding mainly describes about the communication of the client and service. For this, there are protocols corresponding to the binding behavior which will take care of the communication channel. There are different protocols which we use for the different types of bindings. E.g. HTTP, TCP, MSMQ, Named Pipes etc.
Behavior is used for the common configurations that could be for endpoints. When we use the common behavior, they affect to all the end points. Adding the service behavior affect the service related stuff while the endpoint related behavior affects the end points. Also operations level behavior affects the operations.

50. What are different types of Contracts supported?
A. There are mainly 5 type of contracts used in WCF service:
a. Service Contract
b. Operation Contract
c. Data Contract
d. Message Contract
e. Fault Contract

Cont…
Author: Pawan Awasthi      Posted Date: 09 Mar 2013
Interview Questions for 3-6 years experienced .Net professional
Cont..

31. What are Anonymous methods and Lambda Expression?
A. Anonymous methods are those methods which does not have the name. As they don’t have the name, so there is no way to call these methods. These methods are created by using the work delegate as below:
button1.Click += delegate{listBox1.Items.Add(textBox1.Text)};
Lambda Expression: It’s an easy way to create anonymous functions. It is also an anonymous function which has the capability to contain expressions and statements. We can create the delegate and expression tree types using the lambda expression.
For more details regarding the anonymous method and lambda express, you can go through the below link:
http://www.codeproject.com/Articles/47887/C-Delegates-Anonymous-Methods-and-Lambda-Expressio

32. Multithreading. How to implement Multithreading?
A. Executing more than one process simultaneously called as multithreading. To implement the multithreading concept, we need to use the System. Threading .dll assembly and the System. Threading namespace.
To write the thread program, we need to create a class with the method. Now we can create the thread object and then pass the method by using the class object to the method.
After that we need to create the ThreadStart delegate which will call the actual method of the class.
You can go through below link for more explanation and other details regarding the implementation and the code snippet:
http://www.codeproject.com/Articles/1083/Multithreaded-Programming-Using-C

33. Which interface is used to-
a. Convert Boolean values to Visibility values?
b. Compare two integer values?
c. Compare String values?
A. Check the below interfaces which are used in these scenarios:
a. Convert Boolean values to Visibility values?
b. Compare two integer values?- IComparable interface
c. Compare String values? IComparer interface


SQL Server

34. What is the difference between a View and a Cursor?
A. View: It is one of the database object which is also called as virtual table. We can also say that it is a window through which we can see some part of database. View is also called as stored query because we are going to fetch some data using View.
View doesn’t contain any data. It’s just a virtual table which is used to get the records from the base table for which the view is created. View is faster than ad hoc queries because when we create the view and execute it once. Next time onwards it will be available as the compiled format. So whenever the view is called, it will just execute rather than compiling.
Cursor: Cursor is a database object which is also the buffer area which is created as a result of any sql statement to hold the intermediate values.
Views are used to format the rows individually. By using the views, we can process the individual rows. There are 4 types of cursors in Sql Server-
a. Static Cursor
b. Dynamic Cursor
c. Key set cursor
d. Read-only cursor

35. How to execute multiple update on different conditions in a single query?
A. To execute multiple update using a single Sql update statement is the new feature available with the SQL Server 2008. In this, we can update multiple rows using a single update command.

36. Left outer joins and Right Outer joins
A. Joins are used to join 2 or more tables using some conditions. There are 3 types of Joins in SQL Server database-
a. Left Outer Join
b. Right Outer Join
c. Full Join
In order to extract the matched row from both the tables and unmatched row from the first table, left Outer join is used. The syntax for left outer join condition is:
T.Col1* = T2.Col1
In order to extract the matched row from both the tables and unmatched row from the second table, right Outer join is used. The syntax for right outer join condition is:
T.Col1 = *T2.Col1
In order to extract the matched row from both the tables and unmatched row from the first table and then unmatched row from the second table, full join is used. The syntax for full join condition is:
T.Col1* = *T2.Col1

37. Exception handling.
A. Exception Handling is the way to handle the unexpected error. From the SQL Server 2005 version, try…catch block is also supported to catch the exceptions in SQL Server database. There is various other ways to catch the error like @@Error which is the global variable and used to get the error. RaiseError is another inbuilt method which is used to display the error.

38. What is Performance Tuning? How do you implement it.
A. Performance Tuning is the process through which we can optimize the SQL Server objects like functions, triggers, stored procedure so that we can achieve high response time to the front end. In the performance tuning process we generally check for the below point and optimize the objects processing:
a. Through Query Execution plan, check for the processing time of the query execution.
b. Check the join conditions and break all the condition for executions of the queries individually
c. Check for the error prone process, conditions in the queries.
d. Check for the loops whether they are terminated if any error occurs
e. Check for the processes which are taking more time in execution and how to reduce the response time.

39. Difference between Having and Where clauses.
A. When the where clause is not able to evaluate the condition which consists of group functions, Having clause is used. Having clause is always followed by the Group By clause.
Where clause is used to filter the records based on the conditions. If there is the requirement to get the group data in the select statement and where clause is not able to get it, we can use the Having clause.
e.g. Display DeptNo, No.of Employees in the department for all the departments where more than 3 employees are working
SELECT DEPTNO, COUNT(*) AS TOTAL_EMPLOYEE
FROM EMP
GROUP BY DEPTNO HAVING COUNT(*) >3

40. Difference between Temp tables and Tables variables?
A. Temp Table in SQL Server:
a. Temp table is the special type of tables which are used to store the intermediate data of the actual table.
b. Temp tables are only visible to the current sessions of the sql server instance. When the session end, these table data automatically drops.
c. We can’t join the temp tables as they don’t allow the foreign key constraints.
d. Temp tables are created in TempDB database.
e. We can use the same temp table name for the different user sessions.
f. Mostly used in stored procedure to handle the intermediate data.

Cont...
Author: Pawan Awasthi      Posted Date: 09 Mar 2013
Interview Questions for 3-6 years experienced .Net professional
Cont..

21. In how many different ways can JavaScript be used/called in an application?
A. JavaScript can be used for Client Side validation, can also be used for calling of server side methods and functions, can be used for calling the web services etc.

22. What needs to be done to call a JavaScript function from code behind?
A. If we want to call the JavaScript function from the code behind, we need to attach the JavaScript to the events in the page_load eventas:
protected void btnSave_cliekc9object sender, EventArgs e)
{
btnSave.Attributes.Add("onclick,"JavaScript: retrun Validatedata();");
}
Here ValidateData is the JavaScript function which can be used to validate the page data and if validation fails, it will return and will not execute the server side btnSave_click event.

23. Difference between Server Controls and User controls?
A. User controls are used for the reusability for the controls in the application. By using the user control, we can use the same control in the various pages. User controls can be created by combining more than one control. To use the user controls, first we need to register them in the web page where we want to use that control. A separate copy is need in each page where we want to use the user control. User controls can't be included in to the toolbox.
Server controls are those controls which can be found in the toolbox and can be directly drag to the application like textbox, button etc. For the server control, only 1 copy of the control is needed irrespective of the number of web pages. If we want 10 textboxes to be added in our web page, we need only 1 copy of the textbox in the toolbox and can be dragged 10 times.

24. Difference between Var, object and Dynamic types.
A. var is the keyword introduced with .net 3.5 and used to store any kind of data like dataset, data table, int, float, char etc. We can keep any kind of data in the var variable.
var myVar = new String[] {"hello", "world!!"} ;
Here the myVar is the var type variable which is used to store the string array. Like this we can store any type of data into the var.
Object is the type which is used to store the objects of any kind. These objects need to be type caste when required.
Like object mybject = "Hello"
Here the myObject variable of object type is used to keep the string variable. Now when we want this variable value, we need to typecast it like
string strvar= (string) myobject;
Dynamic- It’s a keyword introduces with the .net 4.0 and used to keep the data similar to the var keyword. The difference between the var and dynamic is that the dynamic variable uses the same memory location to store the object and not changes throughout the application.

25. Difference between Functions and methods.
A. in.Net terminology, both are same. in general, we use method in .net but in scripting language we use function like JavaScript function.
Here the difference can be Function always returns a value which method may or may not. It depends upon the return type of the method.

26. Difference between Abstract classes and Interface. Explain with scenario where to implement one?
A. Collection of the Abstract (Incomplete) and Concrete (complete) methods is called as the Abstract class. If there is at least one abstract method in a class, the class must be abstract class.
When there is the similar behavior, we can use the abstract class.
e.g. We want to calculate the area of few component. As this is not generic to the application. We have only few component- like Circle, Ellipse, parabola, Hyperbola, Triangle etc.
So we can create an abstract class and implement it like below:
public abstract class MyAbstractClass
{
// some other concrete members
public abstract void Area();// abstract member
}
Now in the child class, let’s say i have a circle class and want to calculate the area of the circle:
pyblic class Cicle: MyAbstractClass
{
public override void Area()
{
// calculate the area of the circle
}

}
In the similar fashion, we can calcite the area of other shapes.
Collection of abstract members is called as the Interface. When the behavior is not similar, we need to use the interface. All the members of the interface
must be overrides in the child class.
e.g. Print functionality of the application can have an interface like:
interface Inf
{
void Print();
}
Now as this is the generic functionality and can be implemented in any of the page so we have taken it as interface. Now we can implement this functionality in to any page like:
class MyClass:Inf
{
public void print
{
// write details about the print
}
// Here we can implement any kind of print-like print to excel, xml, word all depends on the our decision.
}

27. Different forms of Polymorphism. Differences between Abstraction and Polymorphism.
A. Polymorphism is to use the same function in many forms. The polymorphism is of 2 types-
a. Classical polymorphism (Overloading)
b. AdHoc polymorphism (Overriding)
When the runtime (CLR) find the behavior of class members at the runtime of the program, it is called as the AdHoc polymorphism or Overriding.in this the method name is same but they are implemented in the different class. We use virtual keyword in the base class method to be overrides in the child class using the override keyword.
e.g.
public class MyClass
{
Public int Add(int a, int b)
{
Return a+b;
}
Public int Add(int a, int b, int c)
{
Return a+b+c;
}
}
When the runtime (CLR) find the behavior of class members at the compilation of the program, it is called as the Classical polymorphism or Overloading.in this the method name is same but there prototypes (parameters) are different and it is implemented in the same class.
e.g.
Public class MyBaseClass
{
Public virtual void Show(string message)
{
Console.WriteLine(“Your message is : ”+ message);
}
}
Public class MyChildClass: MyBaseClass
{
public override void Show(string message)
{
Console.WriteLine(“Your new message is : ”+ message);
}
}
Abstraction is the behavior to get the required functionality in the child class. So we don’t matter whatever is written in the base class. We only need to force the child class to implement my required functionality.
Abstract keyword is used to get the abstraction behavior.

28. What are Delegates and Events?
A. A Delegate is an object, which points to another method in the application. Delegate holds, name of the method, arguments of the method (if any) and the return type of the method.
See the below points regarding the Delegate:-
• delegate keyword is sealed type in System. Multicast namespace.
• Delegate works like a function pointer in C language.
• Delegate holds the address of the function.
• Delegate hides the actual information which is written inside the method definition.
• A delegate can hold address of a single function as well as the address of multiple functions.
• There are 2 types of delegate- Single-cast delegate (hold single function) and Multicast delegate(hold multiple functions).
• Addition and subtraction are allowed for the delegates but NOT multiplication and division. It means, we can add delegates, subtract delegates etc.
e.g. To create a single cast delegate, first we can create a class with a method as:
public class DelegateDemo
{
public void Show(string msg)
{
Console.WriteLine(msg);
}
}
Now we can call the method Show using the delegate as:
public delegate void MyDelegate(string message); //declare delegate
now we need to create the object of the delegate with the address of the method as:
DelegateDemo obj = new DelegateDemo();//class object
MyDelegate md= new MyDelegate(obj.Show(“Hello World!!”));
md(); // call the delegate
We can create the events and event handler by using delegate with the below syntax:
public delegate void textChangedEventHandler(Object sender, TextEventArgs e);
This event handler will be used to handle the textbox text changed event.
We can get more details about the delegate and events from the below link:
http://msdn.microsoft.com/en-in/library/orm-9780596521066-01-17.aspx

29. Covariance and Contra-variance.
A. covariance and contravariance are the new features added with the .net 4.0. They are basically used for the implicit reference conversion for different .net types like array, delegate, and generic etc
You can go to the below link for more details with the examples that how we can use the covariance and contrvariance to implicate reference conversion:
http://blogs.msdn.com/b/csharpfaq/archive/2010/02/16/covariance-and-contravariance-faq.aspx

30. What are Extension methods?
A. Extension methods are special types of methods which are static methods but called as the instance methods. The extension methods are added with the .Net framework 3.5 and with the Visual Studio 2008.
These methods won’t affect the existing class and the label. These methods are used for the extra behavior which the calls can provide. There is no need to build the class again if we add any extension method to the class.
There are various inbuilt methods added in .Net 3.5 with the introduction of LINQ. We can see the extension methods like Order By when we use the Linq as:
e.g.
int[] numbers = { 10, 45, 15, 39, 21, 26 };
var orderedNumbers = numbers.OrderBy(a => a);

Cont..
Author: Pawan Awasthi      Posted Date: 08 Mar 2013
Berkadia Services asp.net, c# Interview questions for 4+ years experience
Hai Priya Jain,
Thanks for Posting the questions asked in the Berkadia Services, Hyderabad. Hope these questions will definitely will be helpful for those who are gong to attend the interview in the same company.
Below I have tried to post the answers of these question with the hope that it will be useful for all of us:

1. What is Group By Clause?
A. Group By clause is used to group the rows, depending upon one or more values so that the group function can be applied to each group. if the 'Where' clause exists in the select statement, then Group By clause always be followed to the 'Where' clause. If in the select statement, there are non-aggregate columns, then in the Group By clause we need to add all those columns except the aggregate columns.
E.g. Display the DeptNo, Sum of Salary, Number of Employees from Emp Table:
Select DeptNo, Sum(Sal) as TotalSalary, Count(*)
From Emp
Group By DeptNo;

2.Do you have knowledge in SSIS/SSRS in SQL Server?
A. Yes, SSIS and SSRS are the component of MS-BI where the SSIS is used for the integration services like loading of data from one data base to another database with all the validations. Here we need to create the service which will run automatically to load all the data from one of the data base to another database like from oracle database to Sql Server database.
SSRS is used for reporting services where we can create different types of reports- like simple reports, cross tab reports etc.

3.Have you ever used scheduler in SQL Server?
A. Yes, We can schedule the Sql related jobs using the Scheduler. Those jobs will run as per the schedules time in the Sql Server.

4. Using Indexes and its advantages.
A. Indexes are one the database objects which are used to improve the performance of the database queries. it reduces the table scan while retrieving the data from the database and the search gets fast-
There are 2 types of indexes used in the SQL server:
a. Clustered index
b. Non clustered index
There are 3 more types of index but those comes under the above two-
a. unique index
b. Composite Index
c. XML Index-added in SQL Server 2005

5.SQL Profiler
A. Sql Profiler is a tool in the Sql Server management Studio which is mainly used to track the data from the front end. It is used to see the actual execution of the queries, stored procedure for the input data. So by using this tool, we can check all the input data which is coming from the front end or from another queries and can validate that data against the actual data. This tool is mainly used for fixing the issues related to the database.

6.How do you check the performance of SQL queries?
A. Sql Queries performance can be checked by using the Query optimization. we can check the query execution plan that how much time the query is taking to execute and then we can find-out that which part of the query is taking more time. The issue could e incorrect joins which is leading for more time to get the results. or in-proper sub-queries. By query execution plan, we can track the execution of the queries and then optimize it if required.

Category: C#/ASP.NET

1.How can we know the methods available in a raw dll file?
A: Reflection is the concept to track the dll's class, methods, properties on the fly. By using Reflection, we need not to add the dll in to the application, it will add the dll in runtime and can retrieve all the information inside the dll.
Using .Net Reflector.

2.Difference between Web services and WCF Service.
A. WCF service can be invoked by any protocol while the Web Service supports on HTTP protocol.
To make a new version of WCF service, we just need to add one more end point in the config file and there is no need to change in the code part.
If we want the create the new version of Web Service, we need to recreate the service.
WCF service are agile while web service is not.

3.How to perform authorization in asp.net?
A. To perform the authorization in ASP.net, we need to add the authorization tag in the Web.Config file. And then we need to allow or deny the users through this tag as below:
authorization
deny users="?"
authorization
it will deny the anonymous users.

4.ASP.NET page lifecycle.
A. ASP.Net page life cycle starts with the client requests. The request first goes to the IIS(Internet Information Services). The IIS takes the requests and then send to the utilities- InetInfor.exe and ASPNet_ISAPI.dll. These two utilities takes the request and validate for the correct requests and then filters as the directory and the web page name. Now the request further move the worker process(w3wp.exe) to check for the existing web directory and then AppDomain for the current page. If the page not found, then the request further moves to HttpPipeLine and executes via ProcessRequest method by generating its events- init, load, render, unload..etc.

5.What are HTTP Handlers and HTTP Modules?
A. HttpModule and HttpHandler are two components which comes with the HttpPipeLine while moving the request to HttpPipeLine. here HttpModule is used to check the request authentication and then routing so that it should be received by the correct handler(HttpHandler) for the process and then after processing , it validates the request and then route it back to the client.
Hope it will be helpful for all of us for attending the interviews..
Author: Pawan Awasthi      Posted Date: 03 Mar 2013
Interview Questions for 3-6 years experienced .Net professional
Cont..
11. CLR and DLR?
A. CLR (Common Language Runtime) is the utility in the .Net framework to run the application. It is the runtime engine which actually executes the application with many responsibilities like taking care of memory management, versioning, CasPol etc.
DLR is new with .Net 4.0 which is the Dynamic Language Runtime and used to run the application on the fly wherever required. CLR runs as statically while DLR runs dynamically.

12. In case more than one version of an installable is installed, which version is invoked by default?
A. By default the CLR will take and invoke the latest version of the dll and execute it accordingly. There could be the same name assemblies exists in the GAC but they will have different versions altogether for their uniqueness.
So while running the application, CLR takes the latest version assembly and use in the application.

13. What are Globalization and localization? How to implement them?
A. Globalization is the concept of developing the application in more than one language while the Localization is used for a particular language. Like if we develop the application in more than one language we need to create the resource files (.resx) by using System. Globalization and when we open the application in a particular language, then the localizations used to convert that application to the selected language.

14. What is assembly, GAC? Where they are physically located?
A. Assembly is the collection of classes, namespaces, methods, properties which may be developed in different language but packed as a dll. So we can say that dll is the assembly.
There are 3 types of assemblies- Private Assembly, Shared Assembly, and Satellite Assembly.
GAC (Global Assembly Cache)- When the assembly is required for more than one project or application, we need to make the assembly with strong name and keep it in GAC or in Assembly folder by installing the assembly with the GACUtil command.
To make the assembly with strong name:
SN -k MyDll.dll
And to install it in GAC:
GacUtil -i MyDll.dll
GAC assemblies are physically stored in Assembly folder in the system.

15. How to configure HTTPS for a web application?
A. To configure the HTTPS (HTTP with Secure) for the web application, we need to have a client certificate. We can purchase the client certificate from the trusted providers and then we need to install that provider for our site. By implementing the HTTPS, all the data which is passing will be in encrypted format and will be more secure.

16. What are in-proc and out-proc? Where are data stored in these cases?
A. In-Proc and Out-Proc is the types of Sessions where the session data can be stored in the process memory of the server and in the separate state server.
When the session data is stored in the process memory of the server, the session is called as the In-Proc server. In this case when the server is restarted, the session data will be lost.
When the session data is stored in the separate server like in state server or in Sql Server, the type of session is called as the Out-Proc session. In this case, if the server where the application is running is restarted, the session will be still remain in the separate servers.
So in the in-Proc session state, the session data is stored in the Process memory of the Server where the application is running.
In the Out-proc session state, the session data is stored in the separate server- may be state server or in sql server.

17. When the View state is saved, and when is it loaded? How to enable/ disable View states?
A. View State data is stored in the current page in base64 encoded format. It gets loaded with the page and displays the values to the controls after the decoded. Internally it actually saves the checksum of all the control data where the view state is enabled.so that when the page gets loaded due to any post back, it again finds the checksum and then decodes the Base64 encoded string and gets back the same data to the controls. We can see the view state base 64 encoded string in View Source of the page. It will be like _VIEWETATE="DSDSDF8DGDGDFGFD5FDGGDJFF23BNN457M9UJOG" this.
View state won't take the client or server memory to keep the view state data.

18. Difference between GET and POST. Which one is more secure?
A. GET and POST methods are used for the data transfer between the web pages. GET mainly used for small data which is not secure because in case of GET method, the data which we are passing will be visible in the url so we can't keep the secure data which will be visible in the url. There is also limited data which can be passed in case of GET method (max 255 character).
POST is used for transferring the huge data between the pages where we can keep the secure data and can transfer it. In case of using the POST method, the data which is transferring between the pages will not be visible so it is more secure than the GET method. Also there is no limit for POST method to post the data to the next page.
POST is more secure.

19. What are Razor engines? How is it diff from ASP Engines?
A. RAZOR engine is the new concept in the MVC 3 which is mainly used to create the views in the MVC applications. It created the xhtml pages for the MVC application and xhtml pages can be generated automatically by using the Razor engine.ASP engine create the aspx pages while Razor engine creates the xhtml pages.

20. Pros and cons of JavaScript and AJAX.
A. JavaScript is a scripting language and mainly used for client side validation. We can validate the client side data before sending to the server. So by this we can improve the performance of the application.
Ajax is Synchronous JavaScript and XML which is used for the Asynchronous calls from the server. It uses internally the JavaScript for making the call and use XML for the Data Transfer. It basically uses the XmlHttpRequest for the asynchronous calls to the server and communicates with the xml data which is platform independent. So Ajax can be used with any technology.

Cont...
Author: Pawan Awasthi      Posted Date: 27 Feb 2013
Interview Questions for 3-6 years experienced .Net professional
Hai Rohit,
Thanks for posting the short questions for 3-6 years guys. These questions will be helpful for those who are preparing for the interview or attending the interviews. This will be helpful for the last minute preparation in quickest way.
Below I am trying to provide the answers for these questions. If anyone has better answer, please reply to this post as that will be useful for all of us.

As the system is not allowing me to keep all the answers as in one post so I am dividing the questions and posting them in continuous posts.

CLR and C#

1. Types of Authentication and Authorization in IIS.
A. Types of Authentication: Anonymous Authentication, Windows Authentication, Digest Authentication
Types of Authorization:- Anonymous

2. Types of Authentication and Authorization in ASP.Net.
A. Types of Authentication: Windows Authentication, Forms Authentication
Types of Authorization:- File Authorization and URL Authorization

3. ASP.Net Life cycle.
A. The request starts with the client and processed through IIS. In IIS, there are 2 utilities- INetInfo.exe and ASPNet_ISAPI.dll the InetInfo.exe checks for the syntax and semantics of the request and then the request goes to the ASPNet_ISAPI.dll which is the filter to filter the .aspx files. Here the URL request split in to 2 parts- virtual directory and webpage. Now worker process which is nothing but the application factory basically contains all the virtual directories and checks for the current virtual directory. If this is first request, then there will be no Virtual directory available. Now the worker process (W3wp.exe) creates a memory area called as AppDomain to check for the current page. As AppDomain is the Page Handler factory so it contains all the processes pages. If this is the new page then it will not find here. The request further move to the HttpPipeline where the actual execution of the page happened by using the ProcessRequest method and creates the events of the page. After creation of event and execution of all the event, the html page gets back to the user.

4. Page Life Cycle.
A. There are few events which gets generated during the page execution like: Page_BeginRequest, Page_Init, Page_Load, Page_Prerender, Page_Render, Page_Unload etc
For the details of the page life cycle, you can follow the previous question.

5. What are types: Value Type and Reference Type?
A. Value type holds data directly, Value type stored in the stack memory, We can get the direct value of the value types. Value type data type can’t be null.
Reference types: This type doesn’t hold the data directly. They hold the address on which the actual data present. They stored in heap memory, Can have default values.
We can make and work with null reference type.

6. Boxing and Unboxing: Terminology, Advantages and Disadvantages.
A. Converting the value type data type in to the Reference type is called as Boxing. Converting the Reference type data type and keep its value to stack is called as the reference type.
byte b= 45;
Object o = b.Tostring();
The Advantage of boxing and unboxing is that we can convert the type of the object in to another type. The disadvantage is that it requires lot of memory and CPU cycles to convert from one type to another type.
Object o=10;
Int i= Convert.ToInt32(o.ToString());

7. What is Type Safety?
A. TypeSafe is a way through which the application or framework that the memory will not be leaked to outside environment. E.g. C# is the type safe language where you must have to assign any object before using it. In VB.Net it will take the default value. So C# is the type safe language while VB.Net is not.

8. What is Strong Name?
A. Strong Name (SN) is used to make the dll as the unique as:
SN -k fileName.dll
Now it will have the unique name. This assembly when placed in the GAC, it will treat as the unique with its version number and other details. 2 assemblies with the same name can exist in the GAC but both will have different version. The CLR takes the latest version assembly while running the application.

9. What are Extensions, modules and handlers?
A. HttpModule and HttpHandler are the utilities which are used in the HttpPipeline under the ASP.Net page life cycle. When the request received to HttpPipeline, the HttpModule checks for the Authentication of the request and then it route the request to the respective handler. After that HttpHandler takes that request and process it. After Processing the request again the HttpModule takes the response and send it back to the worker process and finally to the user.

10. What is worker process?
A. Worker process (w3wp.exe) is an executable which is also called as the Application Factory. This is used for the execution of the request and handling of the request for the current web page.

cont...
Author: Pawan Awasthi      Posted Date: 27 Feb 2013
Object Oriented Programming Concepts - OOP Concepts
Hai Michael Sadgun Rao Kona,
Thanks for sharing the details about the OOPs concepts. it will be really helpful for all those who are learning these concepts.
But it would have better if you would have shared by some examples which helps in understanding of their use in the real world.
Author: Pawan Awasthi      Posted Date: 21 Feb 2013
ASP.NET Puzzles.Try To Solve
Hai Ritu,
Thanks for posting good and tricky questions in DNS. These questions will really helpful for those who are ready to go for interviews:
I am trying to post the answers for the questions. Please if anything is wrong then please correct me and provide the correct answer with explanation:

1. Heart of ASP.NET Framework?
A. I would go with CLR(Common Language Runtime) which is used for running the application. Not only for running the application but taking care of many things- Like Automatic Memory management, CasPol, version system etc.

2. Which component is responsible for converting IL Code to Native Code?
A. My answer will be JIT(Just In Time) Compiler which is used to convert the MSIL(IL) code to machine level code(native Code).

3. Name the types of JIT compiler
A. 3-types
a. Pre JIT
b. Econo JIT
c. Normal JIT

4. Which component is responsible for service oriented communication?
A. SOA(Service oriented Architecture) which is the framework for designing the Service Oriented Application. It has mainly 4 rules on which each SOA application is conform to.

5. Which component contains the subset of types and rules for language inter-operation?
A. RCW(Runtime Callable Wrapper) and CCW(COM Callable Wrapper) are used for the interoperability in .Net

6. Which component is responsible to allow the programmer to insert 2-D and 3-D graphics and animation?
A. WPF(Windows Presentation Foundation)

7. List of new components of .NET 3.0 and above versions?
A. There are 4 new componenets added with the .Net Framework 3.0
a. WWF(Windows Workflow Foundation)
b. WPF(Windows Presentation Foundation)
c. WCF(Windows Comunication Foundation)
d. WC(Windows Cardspace)

8. Which component is responsible to take care of controlling the flow of different operations in an application?
A. WWF(Windows Workflow Foundation)

9. Name a component working across platforms / devices / languages using HTTP and XML?
A. Web Services and WCF(Windows Communication Foundation)

10. MVC means
A. Model View Controller

11. Name the types of Polymorphism.
A. 2-types
a. Classical Polymorphism (Overloading)
b. Ad Hoc Polymorphism (Overriding)

12. Is multiple inheritance allowed in C#?
A. Not directly. By using Interfaces, we can achieve the multiple inheritance feature.

13. Can static method access non-static data members?
A. Yes, Create the object of the class and use its members.

14. Which keyword is used to declare indexer?
A. Not sure about the keyword. We declare the indexer using [].

Hope it will be helpful for the members.
Author: Pawan Awasthi      Posted Date: 21 Feb 2013
SQL- The 50 points Last Minute Revision
Excellent work. It will really be helpful for all who are just going to the interview and want the last minute preparation to remember the point.
Thanks for sharing.
Author: Pawan Awasthi      Posted Date: 14 Feb 2013
.Net Interview Questions and Answers
Hai Dipti,
Thanks for sharing the questions and couple of answers. They will be very helpful for those who are either preparing for the interviews or attending the interviews.
Anyway, I am providing the answers which you left out with the hope that they will also be useful for others as:
2)What is Thread pool?
A. Thread Pool is collection of threads where the thread gets executed based on their priorities. High priority thread will get executed first and then the low priority thread will be in the queue.
4)Difference between delegate and events?
Both are similar...but the delegate is mainly encapsulate the internal methods.
We can declare the vent and use the delegate on that event.
You can go to the below link for the example so that it will be more clear:

http://csharpindepth.com/Articles/Chapter2/Events.aspx

Author: Pawan Awasthi      Posted Date: 12 Feb 2013
Ultrabook Convertible Application Design Considerations
Hai Tony,
Thanks for sharing the article related to Ultrabook Application Design features. Hope the members will get benefited with it.
Author: Pawan Awasthi      Posted Date: 10 Feb 2013
Microsoft Technical round
Hai Priya Jain,
Thanks for posting the questions asked by the Microsoft People. It will be helpful to other members before going for the interviews. I am trying to post the answers as below:

1. Interface, abstract classes. most of the questions from this topic.
A. Collection of abstract members and concrete members are called as Abstract Class.
Collection of the abstract members is called as the Interface.

2. Reflection basics.
A. Reflection is the way to work with the class and find the class types on the fly without adding the dll references. We can get the dll details on the fly using the reflection.

3. Statement management concepts.
A. Web is stateless so to retain the values of the controls during the post back implementation, we need to maintain the state of the controls. There are 2 ways to maintain the state of the controls-
1. Client Side State management Techniques- View state, Query string, Hidden Controls, Cookies etc
2. Server side State management techniques- Session, Application, Cache and Profiles etc

4. Difference between virtual and abstract methods?
A. Abstract members must be implemented in the child class while the virtual members may or may not be.

5. Can we have virtual constructors?
A. This concept is in C++ and i think there is no Virtual Constructor in C#.

6. difference between tcp and HTTP protocol
A. TCP protocol is used for intranet while HTTP protocol is internet.

7.What is ViewState?
A. Persisting of form data automatically during the post back implementation is called as View state.

8.how to prevent instance of a class to be created?
A. By using the Private Constructor, we can restrict the class to be instantiates.

9. what is the use of constructor?
A. to instantiate the class members. it basically create the class members in the memory.

10.what is abstract class?
A. Collection of Abstract and concrete members is called as abstract class.

11. read-only and const keyword differences.
A. Constant is initialize at the compile time while the read-only at run time. The value of Constant can never be changed while running the application, but the read-only value can be changed at the run-time.
Author: Pawan Awasthi      Posted Date: 10 Feb 2013
.NET interview questions for 5+ years of experience - OOPS, C#, WPF, .NET Fundamentals
Hai Saravanan,
I tried below the answers of the questions. Please if anyone is having good answers for any of the question, please reply to the post as it will be helpful for others as well as for myself.

1. What is the difference between abstract and interface?
A. Abstract Class is the collection of Abstract and Concrete members and the Interface is the collection of Abstract members only. Here Members means the Methods, Properties, events etc.

2. Is it possible to use properties and events in an interface?
A. Yes, In Interface we can write the abstract properties and abstract events. Abstract means in complete. We can't write the full definitions for any of the members in the interface.

3. What is an explicit interface implementation?
A. Explicit Interface is the interface where we need not to inherit from the interface but we can use the same interface inside the class members by providing its name before the method implementation.
e.g
interface Inf1
{
void Show();
}
interface Inf2
{
void Show();
}

Now If I want to implement both the interfaces, we can use them as:

public class DemoClass:Inf1,Inf2
{
public void Show()
{
Console.WriteLine("Interface 1 method");
}
public void Inf2.Show()
{
Console.WriteLine("Explicit Interface 2 method");
}


4. When will we go for an explicit interface implementation?
A. When we have same methods in more than one interfaces and we want all of them to be implemented in the class, then to differentiate, we need to implement them explicitly using the explicit interface.[as above]

5. What is the difference between value type and reference type?
A. value type hold data directly while the reference type holds the memory location and in that memory location, the actual data exists. value types stored in the stack memory while the reference types stored in the heap memory.

6. Is string reference type or value type?
A. String is the reference type as it holds the data in the heap memory.

7. String is immutable. Why and how will you over come this issue?
A. String objects is immutable because once the data is allocated to the memory location, the data can;t be changed. if we need to the data to be replaced with the new data, we need to create another memory location and paste the same data.

8. How will you create a thread?
A. Using the System.Threading namespace.
Here we can create a thread object and pass the method which will be used for the thread.
Create a class and method inside the class.
create a Thread object and pass the method.Start the thread using the ThreadStart delegate.

9. How will you start a thread?
A. Using the ThreadStart delegate.

10. What are the difference between delegates and events?
A. In actual scenario when we see the IL for both, it generates the same IL(Intermediate Language) or MSIL.
When we declare delegate, event keyword is used as the modifier. Delegate is used for the hiding the actual method and implementation for the security reasons. it support + and - operators so that we can add and subtract two delegates. What that delegates do, is defined by the action events.

11. What is GAC?
A. GAC(Global Assembly Cache). Its the centralized location to store the assemblies which are required by multiple application. When the assemblies are shared by more than one users or application, we need to place in the assembly folder. This assembly folder is called as GAC. All the assemblies in this
folder are having the Strong Name(SN) for the unique identification. The assemblies having the same name can be placed in eh GAC but they will have the separate version number.
We can create the strong name of an assembly by using the below command:
SN -k abc.dll
After creating strong name, we need to place that assembly in the GAC by using the below command:

GACUtil -i abc.dll


12. How will you place an assembly in GAC?
A. To place the assembly in GAC, the assembly must have the strong name and then only we can place it in the GAC. To place the assembly in the GAC, we can use the below command in the Visual Studio Command prompt:

GACUtil -i abc.dll

This command will install the assembly in the GAC.
To Uninstall, we can use the below command:

GACUtil -u abc.dll


13. How will you trigger GC to clean up memory?
A. We can force the Garbage collection to call explicitly by the below method:
GC.Collect();
This method will force the garbage collection to run and free up the memory allocated to the objects.

14. C# - Managed Code; Who manages what?
A. C# is the managed code because the code which is run through the CLR is called as managed code. CLR(common Language Runtime) is the execution engine which make sure that the code which runs through this execution engine doesn't have any memory leak or by pass the object and so called as managed code execution.

15. Is it possible to create unmanaged code by C#?
A. The code which doesn't run through CLR is called as Unmanaged code like VB 6.0 code or VC++ code which is when passed through the Visual Studio, the CLR skips that code and not executes it. For these type of code, we need to explicitly claim the memory management as it will not be taking care by the CLR. Also we need to make sure that the memory will not leak through some other process.

16. What is the difference between C++ and C#?
A. C++ is the object oriented technology which is not the type safe, need to handle the memory management by the programmer, use of pointer makes the C++ as unsafe because pointer uses the memory references.
C# is the pure object oriented, type safe language where the memory managed by CLR automatically. No use of pointer so its type safe. All the declaration for the variable need to be initialized else it will show the compile time error. It doesn't take the variable value automatically or default.

17. How will you handle exceptions in C#?
A. The exceptions occurred by the program can be handled by the Try..Catch blocks. For the code where the exceptions can occur, we can keep the logic in the try block and the to handle that error, we need to add the catch block to throw the exception and show in form of the message.

18. Is it possible to have finally block without catch?
A. Yes, finally block is possible without the Catch block. If we are sure that we won't get any exception in the try block, then we can skip the catch block and directly can write the finally block.
Finally block will always executed whether there is any exception occurred in the try or not. So the code lie to disposing the objects, closing the connection, making the value as null, we use the finally block as it should run always.

19. If catch throws an exception, will finally block gets execute?
A. Yes, finally block will always executed irrespective of catch block. If there is an exception, the control will move the the catch block and after the catch block completion, the finally block gets executed.

20. What is the use of finally block?
A. Finally block is used to free-up the memory, closing the objects, Closing the connections, disposing the objects etc.

21. What is cross thread exception?
A. When the exception occurred in a thread because of other thread execution, the exception is called as cross thread exception. In this case, either of the thread won't executed.

22. What is attached property?
A. These properties are the special dependency properties which doesn't have the wrapper. These properties allows the child elements for specifying the parent element values.

23. What are the advantages of WPF over windows forms?
A. There are many advantages of using the WPF like;-
1. Multimedia integration
2. 3-D support
3. We can create the animations, story etc using the WPF application

24. What is dependency property?
A. Dependency properties are special type of properties which are static properties but called as the instance properties.
Below is the syntax for creating and registering the dependency properties:

// Dependency Property
public static readonly DependencyProperty property=
DependencyProperty.Register( "propertyName", typeof(propertyType), typeof(parentControl),null);


25. What are the different types of bindings?
A. There are various types of bindings supported by the WCF. Bindings re used that how the service will be connected or get accessible by the clients.
1. BasicHttpBiding Binding
2. WSHttpBinding Binding
3. WSDualHttp Binding etc

26. How will you change the shape of a button?
A. We can use the control template to create the style of the button.


27. What is the difference between control template and styles?
A. Style is used to apply the styles to more than one controls.We can change the default appearance of the control by applying the property. For example if we want to change the Font Size and Font size and Font family to all the text boxes, we can create the style and then apply the style to the text-box controls.
ControlTemplate mainly used for the visual structure and visual behavior of a control. We can apply the appearance of a control by new ControlTemplate and then apply it to the controls.

28. Could you call a method by binding?
A. No, Binding is used for how to make the communication of service to the client. e.g HttpBinding, TCPBinding etc

29. What is a value converter?
A. Value converter is used to convert the one type to another types like Currency converter convert the string to currency format.

30. What is a multivalue converter?
A. Multi-Value convert is used to convert the values from one format to another.

31. How will you update the UI if the data is refreshed by some other thread?
A. We can use the Observer Pattern. Observer pattern is used to

32. What is template binding?
A. Template binding is used in template controls. It mainly used to link the property value in the control template to some other templated control property.

33. What is the difference between logical tree and visual tree?
A. Logical Tree is the logical representation of UI controls. It represents the hierarchy of UI controls and elements. The Logical Tree doesn't include inner controls.
Visual Tree is the Logical representation controls with its internal controls. So it also contains the internal controls additional to the Logical tree.

34. What are routed events?
A. These are the special types of events which navigate up or down in the visual tree as per the rounting strategy. Those could be bubbled up event, internal events, inner events etc. These events can invoke more than one other events of the visual tree.

35. What are the different types of layouts in WPF?
A. There are various layouts introduced in WPF:
a. Stack Panel
b. Grid Panel
c. Wrap panel
d. Doc panel
e. Canvas panel

36. What is canvas?
A. Canvas panel is one of the layout control which is used to place the child elements base on there coordinates. The coordinates are relative to the side of the panel. based on the Panel.Left, Panel.Right, panel.Top we can provide the position of the child controls.

37. What are the design patterns you know?
A. Design patterns are the easy way to reduce the problems of the design in the later stages of the software development. There are mainly 3 types of design patterns defined by Go4;
1. Creational- Basically defined the structure of object creation. How the object should be created lie Factory pattern, Abstract Factory patterns, Singleton Design pattern etc
2. Structural- Mainly used for how the object should be structured. e.g. Adapter, Decorator, Facade, Proxy etc
3. Behavioral- How the object behaved in the different scenarios is the main point for the behavioral design patterns. e.g.Visitor, State, Strategy etc

38. How will you find the dependencies in observer pattern?
A. By using the state change, the observer pattern finds the dependency of the objects. Observer pattern basically maintain the list of objects which are interrelated and all the objects implements the common interface. By using the INotifyPropertyChange, we can implement the observer and the observer finds the state has been changed for the particular object and accordingly the UI gets changes.
Author: Pawan Awasthi      Posted Date: 10 Feb 2013
What Events and Delegates do ?
Hai Siva,
I would like to answer your query-
"What is the necessity to hold the reference of the method" the reason is to provide the security to the method so that the method will not be available to access directly. We create the delegate which contains the method of the class and then we call only the delegate not the method. So in thsi way, the actual mthod is hidden.
Author: Pawan Awasthi      Posted Date: 12 Apr 2012
.Net technical round interview Questions for 2+ Years on OOPs, Asp.Net and General coding
Hai Abhijit,
All the best and good luck for your PM round..
I wish that you will crack and get the job..
Author: Pawan Awasthi      Posted Date: 21 Mar 2012
.Net technical round interview Questions for 2+ Years on OOPs, Asp.Net and General coding
Hai Abhijith,
In the PM round, they will mainly consider your Communication skills, your way of communication and there will be hardly few technical questions many be scenario based.
It will not be pure technical but only some technical falvour with more on the communication.
Also they can ask about the work under pressure, your strengths, your weaknesses etc.
So you should be just confident and dont be in hurry while sitting. You need to be cool as they will not concern more on technical. Just be confident and attend the interview. All the best..
Author: Pawan Awasthi      Posted Date: 16 Mar 2012
Check if database exists in MYSQL
Hi Priya,

Good article as this is the common issue which we face frequently while connecting ot he database but we try to resolve this issue by doing lot much R&D.
So its better to first check for the database existance and then go for rest of the tranactions.


Author: Pawan Awasthi      Posted Date: 24 Jul 2011
Temporary Tables in SQL Server
Hai Manoranjan,

Good article regrding the temp tables. But one thing i feel is missing here that why we go for tem tables? is there ny specific reason to go with temp table? i think if you would have explains that too would have been better than this. Also what is the scope of these tables? How is the accessibility options for these tables? whether any user can access these tables data from some other tables?
if possible then include those points also in you article..
Author: Pawan Awasthi      Posted Date: 24 Jul 2011
Internationalization in ASP.NET
Hai,
Good article on globalization and localization...there is always some confusion on me regarding the internationalization, globalization and localization...
this helped me in good way to clearly understand all...these concepts.
Author: Pawan Awasthi      Posted Date: 21 Jul 2011
Enhancing the functionality with Ajax Tab Control
Hi Amit,

Good article for tabs functionality..great one..i really like it as i am learning the AJAX...
Author: Pawan Awasthi      Posted Date: 21 Jul 2011
Introduction to ASP.NET MVC
Hi,

Good article for introductory training...
Great one...i am learning the mvc working..

thank alot
Author: Pawan Awasthi      Posted Date: 21 Jul 2011
Understanding Models, Views, and Controllers
Hi Rishikanth,

Its nice article..really i was looking out for this type article to learn the actual implementation of model view and controller..

Can you please also explain about the MVC2 and how it is different than MVC.

Thanks in advance..
Author: Pawan Awasthi      Posted Date: 21 Jul 2011
Capture and save images from Web camera using C# and ASP.NET
Hai Damu,
This is nice article..very useful..
keep it up..keep on sending more and more article so that i can learn more and more..
Author: Pawan Awasthi      Posted Date: 21 Jul 2011

    Next Results  


Top Contributors
TodayLast 7 Daysmore...

Awards & Gifts

Online Members

swarna ch
More...
 
Copyright © SpiderWorks Technologies Pvt Ltd., Kochi, India