GeekInterview.com
  I am new, Sign me up!
 
GeekInterview.com  >  Interview Questions  >  Microsoft  >  C#
Go To First  |  Previous Question  |  Next Question 
 C#  |  Question 103 of 436    Print  
Can you change the value of a variable while debugging a C# application?
Yes, if you are debugging via Visual Studio.NET, just go to Immediate window.


  
Total Answers and Comments: 2 Last Update: October 11, 2007   
  
 Sponsored Links

 
 Best Rated Answer

No best answer available. Please pick the good answer available or submit your answer.
January 09, 2006 09:34:05   #1  
sahu Member Since: December 2005   Contribution: 323    

RE: Can you change the value of a variable while debug...

Ans:

yes

if you are debugging via Visual Studio.NET just go to Immediate window.


 
Is this answer useful? Yes | No
October 11, 2007 18:32:15   #2  
learnasp Member Since: October 2007   Contribution: 11    

RE: Can you change the value of a variable while debug...
Yes. Go to immediate window in VS.net and use

>eval var newvalue

 
Is this answer useful? Yes | No

 Related Questions

The difference is that static read-only can be modified by the containing class, but const can never be modified and must be initialized to a compile time constant. To expand on the static read-only case 
Latest Answer : As static read-only variables must be initialized in the static constructor (static constructor cannot have parameters and it cannot be called manually), it is efficient to used const variables over static read-only variables if you know the values ...

The word checked is a keyword in C#.  
Latest Answer : Reason is checked is a keyword in C#,but if u want to keyword as an identifier use @ with it.e.g int @checked=3;This works with all the keywords,but it is recommended to avoid it. ...

Make sure that the target type set in the project properties setting is set to Windows Application, and not Console Application. If you're using the command line, compile with /target:winexe & 
Latest Answer : Compile with following syntax at command line     :      csc /t:winexe ...

I was trying to use an "out int" parameter in one of my functions. How should I declare the variable that I am passing to it?
You should declare the variable as an int, but when you pass it in you must specify it as 'out', like the following: int i;foo(out i);where foo is declared as follows: [return-type] foo(out int 

Yes, you can use System.Environment.Exit(int exitCode) to exit the application or Application.Exit() if it's a Windows Forms app.  
Latest Answer : Ans:YesSystem.Environment.Exit(int exitCode) to exit the application or Application.Exit() if it's a Windows Forms app. ...

Some security exceptions are thrown if you are working on a network share. There are some parts of the frameworks that will not run if being run off a share (roaming profile, mapped drives, etc.). To see 
Latest Answer : ans:Yes,this is right. ...

If you try to instantiate the class inside the try, it'll be out of scope when you try to access it from the catch block. A way to get around this is to do the following: Connection conn = null; try 
Latest Answer : ans:Answer: If you try to instantiate the class inside the try, it'll be out of scope when you try to access it from the catch block. A way to get around this is to do the following: Connection conn = null; try {conn = new Connection();conn.Open();}finally{ ...

Value, and its datatype depends on whatever variable we are changing.  
Latest Answer : Ans:value is  implicit name of the parameter that gets passed into the class set method. ...

Classes in the same namespace.  
Latest Answer : Its available only to the derived classes and not all the classes in the NameSpace ...

When overriding, you change the method behavior for a derived class. Overloading simply involves having a method with the same name within the class.  
Latest Answer : Overriding a method involves changing the business logic og the method, however the return type and parameters remain same. However in overloading a method you can have multiple methods with same name but different signatures. ...


 Sponsored Links

 
Related Articles

Application Development in .NET

ASP NET 2 0 Tutorials Application development in NET Client Side Application Development Client applications are applications that run on the client system or the desktop of the user They are closest to the traditional windows based applications and they display forms or windows on the desktop enabl
 

N-Tier Application Partitioning

N Tier Application Partitioning Application partitioning is a vital process as it provides one with the opportunity to clearly define an even distribution of an application s presentation process and key data components without which you may find yourself feeling quite lost The components may be dis
 

N-Tier Application Manageability

N Tier Application Manageability While it is a fact that N Tier applications tend to provide almost limitless scalability the desire to change or add new forms of functionality can present a challenge in more than one arena Growth on a large scale can make capacity planning quite hard When available
 

What is Change Data Capture

Change Data Capture refers to the process of capturing changes which are made to a production data source. Change Data Capture is typically performed by reading the source of database management software logs. Some of the features of Change Data Capture are It consolidates units of works En
 

What happens when a variable is not initialized in main function?

When a variable is not initialized in main function it contains garbage value. This can be well seen from the example below main() { int x; printf(“%d”,x); z= sample() } sample() { printf(“Testing program”); } Output is   &n
 

What happens when a variable is not declared in function definition?

Generally in C program the function definition and calling takes the form as given below: main() { int x,y,z; z=sample(x,y); printf(“%d”,z); } sample(x1,y1) int x1,y1; { int z1; z1= x1 - y1; return(z1); } Here what happens is the values x, y gets passed to x1,y1
 

Application Frameworks in SQL Server 2005

The new application framework of SQL called the Service Broker is a distributed application framework that provides relable asynchronous messaging at the database to database level. It allows internal and external processes to exchange streams of reliable asynchronous messages using extensions of T-
 

Rapid Application Development

What is RAD? One of the conveniences of developing software is that it is not a physical tool that can be lost once it gets developed or manufactured. Codes are used to implement the software and it does not disappear together with the product. We can re-use the code all over again in another softw
 

The Interview Snafu

How to turn someone else’s mistake to your advantage Your dream job is about to become reality. A recruiter gave you the heads up about the perfect position at Humungous Conglomerate, Inc. You went through five interviews as well as a battery of psychological tests mandated by their HR de
 

Effective Controls for Attaining Continuous Application Security

Effective Controls for Attaining Continuous Application Security Throughout the Web Application Development Life Cycle Given the choice, every organization would want secure Web sites and applications from the Web application development phase all the way through the software development life cycle.
 

About Us -  Privacy Policy -  Terms and Conditions -  Contact -  Ask Question -  Propose Category -  Site Updates 

Copyright © 2005 - 2009 GeekInterview.com. All Rights Reserved

Page copy protected against web site content infringement by Copyscape