473,473 Members | 2,004 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

command window / immed window

hi
i have this piece of code but it never shows the ex.tostring in the command
or immed window.
how do i see it?

this is in a class

public void getTeachers()
{
try
{
PermTeacher p =new PermTeacher ();
p.name = "teacher1";
arrTeachers.Add (p);
if (arrTeachers !=null)
Console.WriteLine(this.arrTeachers.Count); //how can i see this?
}
catch(Exception ex)
{
Console.WriteLine(ex.ToString());
}
}
Jul 21 '05 #1
4 1589
> public void getTeachers()
{
try
{
PermTeacher p =new PermTeacher ();
p.name = "teacher1";
arrTeachers.Add (p);
if (arrTeachers !=null)
Console.WriteLine(this.arrTeachers.Count); //how can i see this?
}
catch(Exception ex)
{
Console.WriteLine(ex.ToString());
}
}


That's strange, did you figure out what is going on ?

Gawel
Jul 21 '05 #2
Not 100% sure if I understand you. But isn't Console.... supposed to write
out to the console? Try Debug.WriteLine (Diagnostics namespace) to write to
the other windows

Yves

"juzan" <ch***@hotmail.com> schreef in bericht
news:ur**************@TK2MSFTNGP09.phx.gbl...
hi
i have this piece of code but it never shows the ex.tostring in the command or immed window.
how do i see it?

this is in a class

public void getTeachers()
{
try
{
PermTeacher p =new PermTeacher ();
p.name = "teacher1";
arrTeachers.Add (p);
if (arrTeachers !=null)
Console.WriteLine(this.arrTeachers.Count); //how can i see this?
}
catch(Exception ex)
{
Console.WriteLine(ex.ToString());
}
}

Jul 21 '05 #3
> Not 100% sure if I understand you. But isn't Console.... supposed to write
out to the console?


I am using Console.WriteLine all the time and I have no problem.

Gawel
Jul 21 '05 #4
Hi Juzan,

The console output is directed to the 'Output' window (CTRL+ALT+A) in the
IDE and not the command or immediate windows.

Gary

"juzan" <ch***@hotmail.com> wrote in message
news:ur**************@TK2MSFTNGP09.phx.gbl...
hi
i have this piece of code but it never shows the ex.tostring in the command or immed window.
how do i see it?

this is in a class

public void getTeachers()
{
try
{
PermTeacher p =new PermTeacher ();
p.name = "teacher1";
arrTeachers.Add (p);
if (arrTeachers !=null)
Console.WriteLine(this.arrTeachers.Count); //how can i see this?
}
catch(Exception ex)
{
Console.WriteLine(ex.ToString());
}
}

Jul 21 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Tom Dacon | last post by:
"Open .Net Command Window Here" context menu for Windows Explorer: The reg file described below adds a new menu item to Windows Explorer's context menu when you right-click over a folder (or the...
4
by: juzan | last post by:
hi i have this piece of code but it never shows the ex.tostring in the command or immed window. how do i see it? this is in a class public void getTeachers() { try
2
by: hleewood | last post by:
I'm using VS 2003, VB.Net. For no apparent reason the Command Window no longer functions. It doesn't auto-complete and doesn't recognize any syntax.
2
by: frazer | last post by:
hi sometimes when i execute some commands in the immed window, it says, identifier out of scope. what am i doing wrong. eg n1.Security.SecurityAccessRights.None security is a class in...
4
by: Flip | last post by:
When I'm trying to debug an app in VS, I'm trying to get the value of a variable by typing out a question mark and then the variable name. But when I do that I get an error from the Output Window....
3
by: Chris Lane | last post by:
Hi, Stupid question here but I get the following error when debugging: 'debug.writeline' is not declared or the module containing it is not loaded in the debugging session. I can however use...
2
by: raqib.rafique | last post by:
The immediate window in Vs.NET is giving me problems when i use it with C#. Simple example is I have the following line of code in a function String MyString = "abc.doc"; Then I put a...
1
by: =?Utf-8?B?cm9kY2hhcg==?= | last post by:
hey all, i'm the immediate window debugging my javascript and got the following: ?list {...} list is an array, can someone please tell me what do i do with this? thanks, rodchar
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.