What are the different Debugging tools which come with .NET ?

Wednesday, July 8, 2009


Two debugging tools come with .NET, they are :


1. CorDBG
– command-line debugger


2.  DbgCLR – graphic debugger.


www.codecollege.NET

What are the differences between const and readonly ?

























Sno
const
readonly
1 Can't be static. Can be instance level or static
2 evaluated at design time evaluated at run time
3
Initialized at declaration

Initialized at declaration and in constructor
4
must be of integral type or enumeration
In addition it can have complex types with new keyword and
enumerations are not allowed


www.codecollege.NET

How can you tell the application to look for assemblies at the locations other than its installed location?

You can do that by adding the following entry in the web.config file,


<probing privatePath="c:\yourlibrary; bin\debug" />
www.codecollege.NET

What’s the difference between authentication and authorization?

what is Authentication?


Is a process by which the system decides whether the user is valid to login to the site as a whole.


what is Authorization?


Is a process by which the system decides which are the areas and functionalities the user is allowed to access, at the component level.
www.codecollege.NET

How to download webpage using asp.net and c# ?

See the following code,

using System;
using System.Collections.Generic;
using System.Text;
using System.IO;
using System.Net;

namespace DownloadingFile
{
class Program
{
static void Main(string[] args)
{
WebRequest reqFile = WebRequest.Create("http://www.codecollege.net/2009/07/cloud-computing.html");

WebResponse resFile = reqFile.GetResponse();

Stream smFile = resFile.GetResponseStream();
// Output the downloaded stream to the console
StreamReader sr = new StreamReader(smFile);
string line;
while ((line = sr.ReadLine()) != null)
Console.WriteLine(line);
Console.Read();
}
}
}
www.codecollege.NET

LinkWithin

Blog Widget by LinkWithin

Recommended Books