Answer : ControlToValidate property and Text property.
Saturday, 24 July 2010
Interview Question sabkahub
04:58
Unknown
Sabkahub Services Pvt Ltd,
ASP.NET, C#, SQL SERVER Time Duration: 30 min
______________________________________________________________________________________
1 Question :
Which of the following are correct controls in ASP.NET Source View?()
1.<asp:textbox runat="server" id="Msg" text="Hello, R4R" />
2.<asp:button runat="server" id="Send" text="Send" onclick="Send_Click" />
3. None
4. Both
Answer : 4 Both
2 Question :
Which is used to add event code(on C# Code) for TextBox control in Source view ( ASP.NET)
1. MsgSent.Text = Msg.Text;
2. MsgSent.Text = Msg.Text
3. Both
4. None
Answer :1
3 Question :
Which is used for code-in-line model?
1.< script runat="server">
2.< script javascript="server">
3.Both
4.None
Answer:1
4 Question :
Which is code allows the modification of the head tag at runtime?
1 < head runat="server">
2.< script javascript="server">
3.Both
4.None
Answer :1
5 Question :
How you can change the page title by changing the using C#
1.void buttonSet_Click(Object sender, EventArgs earg)
{
Header.Title :Msg.Text;
}
2.void buttonSet_Click(Object sender, EventArgs earg)
{
Msg.Text= Header.Title;
}
3.void buttonSet_Click(Object sender, EventArgs earg)
{
Msg.Text: Header.Title;
}
4.None
Answer : 1
6 Question :
Which is not used into @Page attributes
1. Async ,CodeFile
2. EnableTheming, MasterPageFile
3. MaintainScrollPositionOnPostback Theme
4. None
5. All
Answer : 4
7 Question :
ASP.NET Supports “Nested Master Page”
1.Yes
2.No
Answer :1
8 Question :
Choose correct Template Within a DataList tag which we can customize
1.AlternatingItemTemplate
2.EditItemTemplate
3.FooterTemplate
4.HeaderTemplate
5.ItemTemplate
6.SelectedItemTemplate
7.SeparatorTemplate
A 1,2,3,4,5
B 1,3,4,5
C 14,5,7
D 1,2,3,4
E,1,2,3,4,5,6,7
Answer :E
9 Write a query to find the days between 12/01/2009 – 12/12/2009.
Answer SELECT DATEDIFF(dd,"24 March 1964","24 March 2001")
10 Does C# support multiple-inheritance?
Answer :yes
11 Is XML case-sensitive?
Answer :yes
12 what is the size of object in c#.
Answer : 8 byts
13 write Update Query in Sql Server :
Answer :
update table_name set Colunm_Name = ‘condition’ where Colunm_Name = 'Argos '
14 What data types does the RangeValidator control support?
Answer : Integer, String, and Date.,
15 How many classes can a single .NET DLL contain?
Answer : many class
16 What is difference between dll and exe?
Answer :
DLL
1. It can be reused.
2. It can be versioned.
3. It is not self executable
4. It doesn't have main function
.EXE
1. It cannot be reused
2. It cannot be versioned.
3. It is self executable.
4. It will have main function.
17 What is View State ?
Answer : ViewState allows the state of objects (serializable) to be stored in a hidden field on the page. ViewState is transported to the client and back to the server, and is not stored on the server or any other external source. ViewState is used the retain the state of server-side objects between postabacks.
18 Can you store multiple data types in System. Array?
Answer : NO
19 What’s the top .NET class that everything is derived from?
Answer : System.object
20 Will the finally block get executed if an exception has not occurred?
Answer : Yes
21 Can multiple catch blocks be executed for a single try statement?
Answer : yes
22 What does the term immutable mean?
Answer : immutable means we can not change the contents at run time,
example of immutable is String
23 write code for JavaScript to refresh a page in 5 second
Answer :
<!-- Codes by Quackit.com -->
<script type="text/JavaScript">
<!--
function timedRefresh(timeoutPeriod) {
setTimeout("location.reload(true);",timeoutPeriod);
}
// -->
</script>
<p>
<a href="javascript:timedRefresh(2000)">Refresh this page in 2 seconds</a> |
<a href="javascript:timedRefresh(5000)">Refresh this page in 5 seconds</a>
</p>
24 Name two properties common in every validation control?
25 Write A Query To Remove The Duplicate Value From A Table
Answer : delete table_name where col_name in(select col_name from table_name group by
col_name having count(*) > 1)
0 comments:
Post a Comment