Hitachi Most Frequently Asked Latest ASP.NET Interview Questions Answers

How To Detect The User's Culture?

VB.NET
Dim sLang As String
sLang = Request.UserLanguages(0)
Response.Write(sLang)

C#
string sLang ;
sLang = Request.UserLanguages[0];
Response.Write (sLang);

What Is The Difference Between Currentculture Property And The Currentuiculture Property?

CurrentCulture property : affects how the .NET Framework handles dates, currencies, sorting and formatting issues.
CurrentUICulture property : determines which satellite assembly is used when loading resources.

Can I Read The Hard Disk Serial # Of The Client Computer Using Asp.net?

No.

Such information is not passed to the server with a http request.

What Is Xxx(src As Object, E As Eventargs)?

xxx is an event handler src is the object that fires the event e is an event argument object that contains more information about the event An event handler is used when one object wants to be notified when an event happens in another object.

What Is The Difference Between Absolute Vs Relative Urls?

Absolute /Fully Qualified URLs

Contain all information necessary for the browser(or other client program) to locate the resource named in the URL
This includes protocol monitor used( i.e http://, ftp://..etc..), Server's Domain name or IP address and the file path
Absolute URL looks as http://localhost/megasolutions/page1.aspx Relative URLs
Only provide information necessary to locate a resourcerelative to the current document(document relative) or current server or domain(root relative)
Document relative URL - page1.aspx
Root Relative URL - /megasolutions/Admin/pagelog.aspx
Hitachi Most Frequently Asked Latest ASP.NET Interview Questions Answers
Hitachi Most Frequently Asked Latest ASP.NET Interview Questions Answers

What Is The Difference Between Url And Uri?

A URL is the address of some resource on the Web, which means that normally you type the address into a browser and you get something back. There are other type of resources than Web pages, but that's the easiest conceptually. The browser goes out somewhere on the Internet and accesses something.

A URI is just a unique string that uniquely identifies something, commonly a namespace. Sometimes they look like a URL that you could type into the address bar of your Web browser, but it doesn't have to point to any physical resource on the Web. It is just a unique set of characters, that, in fact, don't even have to be unique.

URI is the more generic term, and a URL is a particular type of URI in that a URL has to uniquely identify some resource on the Web.

How To Convert Milliseconds Into Time?

VB.NET
dim ts as TimeSpan = TimeSpan.FromMilliseconds(10000) Response.Write (ts.ToString ())

C#
TimeSpan ts = TimeSpan.FromMilliseconds(10000);
Response.Write (ts.ToString ());

Where Can I Get The Details On Migration Of Existing Projects Using Various Technologies To Asp.net?

Microsoft has designed Migration Assistants to help us convert existing pages and applications to ASP.NET. It does not make the conversion process completely automatic, but it will speed up project by automating some of the steps required for migration. Below are the Code Migration Assistants

ASP to ASP.NET Migration Assistant
PHP to ASP.NET Migration Assistant
JSP to ASP.NET Migration Assistant

What Is The Equivalent Of Date() And Time() In Asp.net?

VB.NET
System.DateTime.Now.ToShortDateString()
System.DateTime.Now.ToShortTimeString()

C#
System.DateTime.Now.ToShortDateString();
System.DateTime.Now.ToShortTimeString();

How To Prevent A Button From Validating It's Form?

Set the CauseValidation property of the button control to False.

How To Get The Ip Address Of The Host Accessing My Site?

VB.NET
Response.Write (Request.UserHostAddress.ToString ())

C#
Response.Write (Request.UserHostAddress.ToString ());

How To Access The Parameters Passed In Via The Url?

Call the Request.QueryStringmethod passing in the key. The method will return the parameter value associated with that key. VB.NET
Request.QueryString("id")

C#
Request.QueryString["id"];

How To Display A Wait Page While A Query Is Running?

Refer Asynchronous Wait State Pattern in ASP.NET.

How To Implement Form Based Authentication In Asp.net Application?

For
•VB.NET
•C#

Is There A Method Similar To Response.redirect That Will Send Variables To The Destination Page Other Than Using A Query String Or The Post Method?

Server.Transfer preserves the current page context, so that in the target page you can extract values and such. However, it can have side effects; because Server.Transfer doesnt' go through the browser, the browser doesn't update its history and if the user clicks Back, they go to the page previous to the source page.
Another way to pass values is to use something like a LinkButton. It posts back to the source page, where you can get the values you need, put them in Session, and then use Response.Redirect to transfer to the target page. (This does bounce off the browser.) In the target page you can read the Session values as required.

What Are The Differences Between Html Versus Server Control?

Refer
•ASP.NET Server Controls Recommendations
•Introduction to ASP.NET Server Controls

How Can I Change The Action Of A Form Through Code?

You cannot change it. The action attribute is owned by ASP.NET. Handle Events and Transfer.

Is There Any Control That Allows User To Select A Time From A Clock - In Other Words Is There A Clock Control?

Peter Blum has developed some controls. Check out Peter's Date Package: TimeOfDayTextBox and Duration Text Box Controls.

Post a Comment

Previous Post Next Post