473,394 Members | 1,841 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

Question about Namespaces and the Object Browser.

I can't seem to make sense out of the Object Browser in VB.NET.

Here's one example. I often use the the Sleep method found in the
Thread object like this:

Imports System.Threading

Private Sub test
Thread.Sleep(1000)
End test

When I look in the Object Browser under System I find System.Threading.
Nowhere do I find the Thread object. Where is it? I can't find it
anywhere in the Object Browser.

Another question. The top level of the Object Browser looks something
like this:

System
System.Data
System.Drawing

Why wouldn't Data be found UNDER the System namespace instead of
BESIDES it?

Also when you look at the System namespace you find something like
this:

System
Microsoft
Microsoft.CSharp
System
System.Threading

Shouldn't my Import statement be this:

Imports System.System.Threading?

Is the Object Browser hierarchical or just random?

I'm so confused!!!!!

Nov 21 '05 #1
4 1784
<cr***@hotmail.com> schrieb:
I can't seem to make sense out of the Object Browser in VB.NET.

Here's one example. I often use the the Sleep method found in the
Thread object like this:

Imports System.Threading

Private Sub test
Thread.Sleep(1000)
End test

When I look in the Object Browser under System I find System.Threading.
Nowhere do I find the Thread object. Where is it? I can't find it
anywhere in the Object Browser.

Another question. The top level of the Object Browser looks something
like this:

System
System.Data
System.Drawing

Why wouldn't Data be found UNDER the System namespace instead of
BESIDES it?

Also when you look at the System namespace you find something like
this:

System
Microsoft
Microsoft.CSharp
System
System.Threading

Shouldn't my Import statement be this:

Imports System.System.Threading?

Is the Object Browser hierarchical or just random?


The names in the first row are assembly names, not namespace names. Notice
that namespaces are not necessarily available in a single assembly,
different types residing in different assemblies can be part of the same
namespace.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Nov 21 '05 #2
cr***@hotmail.com wrote:
When I look in the Object Browser under System I find
System.Threading. Nowhere do I find the Thread object. Where is it? I
can't find it anywhere in the Object Browser.


If you press Ctrl+Shift+Alt+F12 (phew!), it will open the 'Find Symbol'
window. In here, type 'Thread' in the 'Find What' box and then click 'Find'.

All the matching symbols will appear in the panel at the bottom. If you
scroll down you'll see 'Thread (System.Threading)' in the list. Double-click
it and it'll take you to the class within the object browser. (It's actually
under mscorlib/Namespaces/System.Threading/Classes).

Hope that helps,

--

(O)enone
Nov 21 '05 #3

Oenone wrote:
cr***@hotmail.com wrote:
When I look in the Object Browser under System I find
System.Threading. Nowhere do I find the Thread object. Where is it? I can't find it anywhere in the Object Browser.
If you press Ctrl+Shift+Alt+F12 (phew!), it will open the 'Find

Symbol' window. In here, type 'Thread' in the 'Find What' box and then click 'Find'.
All the matching symbols will appear in the panel at the bottom. If you scroll down you'll see 'Thread (System.Threading)' in the list. Double-click it and it'll take you to the class within the object browser. (It's actually under mscorlib/Namespaces/System.Threading/Classes).


Got it.

Thanks!

Nov 21 '05 #4
Herfried K. Wagner [MVP] wrote:

Is the Object Browser hierarchical or just random?
The names in the first row are assembly names, not namespace names.

Notice that namespaces are not necessarily available in a single assembly,
different types residing in different assemblies can be part of the same namespace.


OK that makes a bit more sense.

It still seems odd to me that the following 2 Namespaces are totally
different:

mscorlib Assembly
System.Threading Namespace

System Assembly
System.Threading Namespace

It would seem that my Imports statement should say this:

Imports mscorlib Assembly - System.Threading

Instead of this:

Imports System.Threading

Nov 21 '05 #5

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

Similar topics

17
by: clintonG | last post by:
Using 2.0 with Master Pages and a GlobalBaseClass for the content pages. I understand the easy part -- the hierarchical structure of a namespace naming convention -- but the 2.0 IDE does not...
11
by: Random | last post by:
I'm confused about the proper use and usefulness of namespaces. I beleive I understand the purpose is so the developer can put classes within namespaces to essentially organize your code. And I...
2
by: Techno Learner | last post by:
The .NET namespace organization confuses me. I opened a new VB.NET Windows Application and headed for the object browser. It had things such as: (1) mscorlib (2) Microsoft.VisualBasic (3)...
8
by: Florian Daniel Otel | last post by:
Hello all, As the subject says, I am a newcomer to Python and I have a newcomer question wrt namespaces and variable scope. Obviously, I might be missing smth obvious, so TIA for the patience...
4
by: Ronald S. Cook | last post by:
Create a new Windows forms app and you can type Imports System.Runtime.Remoting and start working away. How come I didn't need to add a reference to System.Runtime.Remoting? Thanks, Ron
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
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
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
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
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

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.