Showing my ignorance

hog

Well-known member
Joined
Mar 17, 2003
Messages
984
Location
UK
Although I seem to b able to write some decent apps in VB.NET, well for work anyway and the odd one for fun I do think Im missing some of the basic understanding of the language:(

Can someone enlighten me on this one please?

this line block of code;

Code:
Imports Microsoft.DirectX
Imports Microsoft.DirectX.Direct3D
Imports Direct3D = Microsoft.DirectX.Direct3D

1. wouldnt the first line suffice? If Imports Microsoft.DirectX is imported then doesnt the project then have access to all namespaces within it?

2. I dont understand Imports Direct3D = Microsoft.DirectX.Direct3D at all?

Thnx
 
Importing a namespace doesnt automatically import all the contained namespaces - each one needs to be done individually.

the 3rd one imports Microsoft.DirectX.Direct3d and aliases it to Direct3D. You could use the namespace Direct3D instead of the fully qualified namespace of Microsoft.DirectX.Direct3D
 
Back
Top