Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

MCP Exam question - 70-306   Easy Points

Posted on 2004-09-16
22
Medium Priority
?
181 Views
Last Modified: 2012-05-05
In studing in for this exam I ran acorss this question in a 'purchased' study guide.

There is a function named CCValidate. This function contains several dozen variables and objects. To debug CCvalidate, you create a breakpoint at the top of a function. You run the accounting application within the VS studio .NET IDE and step through the code for CCValidate. You need to examine the contents of the variables and objects in scope on each line of code. However, you want to avoid seeing contents of all vaiables and objects within CCValidate. You also need to complete the debugging process as quickly as possible.
What should you do?

A) Use the Autos Window
B) Use the Locals Window

The study guide says B - is it right? I woulda guessed A
0
Comment
Question by:thenrich
  • 9
  • 6
  • 4
  • +2
22 Comments
 
LVL 4

Expert Comment

by:Kaarthick
ID: 12074792
As said in the document B is correct.

You will get all the values of the variables when you are trying to out a breakpoint and proceed.
0
 
LVL 5

Author Comment

by:thenrich
ID: 12074843
I don't understand your reasoning because of this :

'However, you want to avoid seeing contents of all vaiables and objects within CCValidate'
0
 
LVL 4

Expert Comment

by:Kaarthick
ID: 12074890

thenrich:You need to examine the contents of the variables and objects in scope on each line of code

so i've told that B one was right
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 6

Expert Comment

by:KGreg
ID: 12074899
Yes its correct.  The locals window displays values of variables and properties of objects in a localized context.  

Very helpful window for debugging.

KGreg
0
 
LVL 6

Expert Comment

by:KGreg
ID: 12074913
As you execute code, the Locals window displays the variables in scope.  If variables are initialized 20 lines ahead of your breakpoint, you won't see them listed until you step through to that point.

KGreg
0
 
LVL 5

Author Comment

by:thenrich
ID: 12074917
So does the autos window
0
 
LVL 25

Accepted Solution

by:
RonaldBiemans earned 1000 total points
ID: 12074923
locals will give you  the variables local to the current context
autos will display variables used in the current statement and three statements on either side of the current statement

so A should in my opinion be  the correct answer

because of this line

However, you want to avoid seeing contents of all vaiables and objects within CCValidate
0
 
LVL 5

Author Comment

by:thenrich
ID: 12074936
I guess I'm having a hard time getting past this part of the question:

'However, you want to avoid seeing contents of all vaiables and objects within CCValidate'

That's exactly what the locals windows shows.
0
 
LVL 6

Expert Comment

by:KGreg
ID: 12074951
no its not.  The locals window will show the declared variables.. but not the values, or content as they explain it.

KGreg
0
 
LVL 5

Author Comment

by:thenrich
ID: 12075002
KGreg,
The locals windows does indeed show values. Actually the 2 windows are identical except for the amount of scope they access.
0
 
LVL 6

Assisted Solution

by:KGreg
KGreg earned 1000 total points
ID: 12075007
Never mind.. the answer should be A) Autos.
0
 
LVL 25

Expert Comment

by:RonaldBiemans
ID: 12075009
KGreg is correct.
0
 
LVL 5

Author Comment

by:thenrich
ID: 12075018
thus far we have 2 for answer A and 2 for answer B. Dead even
0
 
LVL 5

Author Comment

by:thenrich
ID: 12075029
ok now we have 2 guys that just changed their minds it's still 2 - 2
0
 
LVL 25

Expert Comment

by:RonaldBiemans
ID: 12075034
sorry my last comment should be thenrich is correct
0
 
LVL 5

Author Comment

by:thenrich
ID: 12075039
It's all bogus!
I've been on .NET since beta and this type of question I could care less about.
0
 
LVL 25

Expert Comment

by:RonaldBiemans
ID: 12075051
You said it Thenrich.

0
 
LVL 5

Author Comment

by:thenrich
ID: 12075058
OK - I'll leave the question open for today and split points to the group that has the most answer for A or B. Right now A is ahead 3 to 1
0
 
LVL 6

Expert Comment

by:KGreg
ID: 12075086
Its a matter of clarity:

"You need to examine the contents of the variables and objects in scope on each line of code."

This line points to Autos

"However, you want to avoid seeing contents of all vaiables and objects within CCValidate."

This line would point to Autos.

"You also need to complete the debugging process as quickly as possible."

This line would be a matter of preference:  Autos or Locals.  Its about how you work.

So the answer should be (A) Autos.

Is this an official MS guide.. or is it published by a 3rd party?  Could be a typo.. or oversight.

KGreg
0
 
LVL 5

Author Comment

by:thenrich
ID: 12075112
Third party from here:

http://www.exact-exams.com/70-306-exam.html

It was cheap - I guess you get what you pay for. But I've been studing from several sources including a kit from Microsoft Press that's actually pretty good.
0
 
LVL 6

Expert Comment

by:KGreg
ID: 12075116
It could have just been an editing mistake..

KGreg
0
 
LVL 96

Expert Comment

by:Bob Learned
ID: 12076885
Another opinion:

"You need to examine the contents of the variables and objects in scope on each line of code"

Autos windows --> "The Autos window displays variables used in the current statement and the previous statement."

Bob
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article explains how to create and use a custom WaterMark textbox class.  The custom WaterMark textbox class allows you to set the WaterMark Background Color and WaterMark text at design time.   IMAGE OF WATERMARKS STEPS Create VB …
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Video by: ITPro.TV
In this episode Don builds upon the troubleshooting techniques by demonstrating how to properly monitor a vSphere deployment to detect problems before they occur. He begins the show using tools found within the vSphere suite as ends the show demonst…
In response to a need for security and privacy, and to continue fostering an environment members can turn to for support, solutions, and education, Experts Exchange has created anonymous question capabilities. This new feature is available to our Pr…
Suggested Courses

885 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question