.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
 
Sign In
Register
 
Win Surprise Gifts!!!
Congratulations!!!


Top 5 Contributors of the Month
Ashutosh Jha
ASPEvil
Jean Paul
satyapriyanayak
SP


Find questions, FAQ's and their answers related to .NET, C#, Vb.Net, Sql Server and many more.

 
Post New Question Subscribe to Interview Questions
 
Quick Links For Interview Questions Categories:
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  OOPs  JQuery  JavaScript/VBScript
BiztalkPatten/Practices.IISWCFWPFWWF
NetworkingAptitudeOthers  All    
 

Interview Questions And Answers

What is update panel and script manager in .NET

Author: Ashutosh Jha          Posted Date: July 30, 2014    Category: .NET Framework     Points: 40

Update panel is used when you are working with some of the asp.net controls like dropdown box, buttons and you don't want the whole page to get refreshed after each event then put that section of controls inside the update panel. And script manager is used to support the update panel. You can define script manager directly from the .net tool box-

<asp:ScriptManager ID="ScriptManager1" runat="server">
</asp:ScriptManager>

And update panel you can use like this-

<asp:UpdatePanel runat="server" id="UpdatePanel" updatemode="Conditional">
<Triggers>
<asp:AsyncPostBackTrigger controlid="UpdateButton2" eventname="Click" />
</Triggers>
<ContentTemplate>
<asp:Label runat="server" id="DateTimeLabel1" />
<asp:Button runat="server" id="UpdateButton1" onclick="UpdateButton_Click" text="Update" />
</ContentTemplate>
</asp:UpdatePanel>

What is message queuing in .NET

Author: Ashutosh Jha          Posted Date: July 30, 2014    Category: .NET Framework     Points: 40

Messaging Queuing is a general purpose method for integrating enterprise applications. Messaging is available on several platforms including Microsoft, IBM and platforms that implement Java.

We can send message from one system to another system using message queuing.

In .NET you can program MSMQ through the System.Messaging namespace

How to validate the listbox for the duplicate values from textbox.

Author: Ashutosh Jha          Posted Date: July 30, 2014    Category: ASP.Net     Points: 40

It can be done like below-

on the button click event of your add button you can check, if the already entered value and the textbox values are same or not. if both are same, don't allow it else write the new value like below-

foreach(listItem item in ListBox.Items)
{
if(Item.Text != txtbox1.Text)
{
lb.Items.Add(txtbox.Text);
}
else
{
//add the new value;
}

How to delete duplicate rows from table in sql

Author: Ashutosh Jha          Posted Date: July 30, 2014    Category: Sql Server     Points: 40

One can achieve this like below-

DELETE FROM table_name A WHERE ROWID > (
SELECT min(rowid) FROM table_name B
WHERE A.key_values = B.key_values);

What is cross page posting in asp.net

Author: Ashutosh Jha          Posted Date: July 30, 2014    Category: ASP.Net     Points: 40

Whenever, you need to deal with the first webpage's control value to different pages of your application , you can do this with cross page posting. So, cross page posting enables you to post the WebPage and WebPage's control values to another WebPage in your asp.net applications.

There are two ways we can use cross page postsbacks in ASP.NET

Suppose you have some controls like textboxes, labels and one button on your first page -
<asp:Button
ID="Button2" runat="server"
Text="Submit Page to secondpage.aspx"
PostBackUrl="~/secondpage.aspx" />

use PostBackUrl and assign the url of second page.
Now on the second page, using PreviousPage property you can receive those values of controls from your first page.

How do you check if a variable is an array in JavaScript

Author: Ashutosh Jha          Posted Date: July 29, 2014    Category: JavaScript/VBScript     Points: 40

if (i2 instanceof Array) {
alert('v1 is Array!');
} else {
alert('i2 is not an array');
}

What is the use of connectionStrings tag.

Author: Ashutosh Jha          Posted Date: July 29, 2014    Category: .NET Framework     Points: 40

<connectionStrings> is the most common section of web.config file which allows you to store multiple connection strings that are used in the application.

<connectionStrings>
<add name ="ConString" connectionString ="Initial Catalog = abc;
Data Source =localhost; Integrated Security = true"/>
</connectionStrings>

what are the purpose of <appSettings> tag

Author: Ashutosh Jha          Posted Date: July 29, 2014    Category: .NET Framework     Points: 40

appSettings tag helps us to store the application settings information like connection strings, file paths, URLs, port numbers, custom key value pairs, etc.

<appSettings>
<add key="ConString" value="Data Srouce=....."/>
</appSettings>

what are the funcnalitity of <httpHandlers> tab in web.config

Author: Ashutosh Jha          Posted Date: July 29, 2014    Category: .NET Framework     Points: 40

HttpHandler is a code that executes when an http request for a specific resource is made to the server. For example, request an .aspx page the ASP.NET page handler is executed, similarly if an .asmx file is requested, the ASP.NET service handler is executed. An HTTP Handler is a component that handles the ASP.NET requests at a lower level than ASP.NET is capable of handling.

What is the use of customErrors tag in web.config file

Author: Ashutosh Jha          Posted Date: July 29, 2014    Category: .NET Framework     Points: 40

<customErrors defaultRedirect ="Error.aspx" mode ="Off">
<error statusCode ="401" redirect ="Unauthorized.aspx"/>
</customErrors>

The customErrors section consists of defaultRedirect and mode attributes which specify the default redirect page and the on/off mode respectively.
The subsection of customErrors section allows redirecting to specified page depending on the error status code.
400 Bad Request
401 Unauthorized
404 Not Found
408 Request Timeout
« Previous12345678910….453454Next »


Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend