Jump to content
Xtreme .Net Talk

Recommended Posts

Posted

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 I'm missing some of the basic understanding of the language:(

 

Can someone enlighten me on this one please?

 

this line block of code;

 

Imports Microsoft.DirectX
Imports Microsoft.DirectX.Direct3D
Imports Direct3D = Microsoft.DirectX.Direct3D

 

1. wouldn't the first line suffice? If Imports Microsoft.DirectX is imported then doesn't the project then have access to all namespaces within it?

 

2. I don't understand Imports Direct3D = Microsoft.DirectX.Direct3D at all?

 

Thnx

My website
  • Administrators
Posted

Importing a namespace doesn't 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

Posting Guidelines FAQ Post Formatting

 

Intellectuals solve problems; geniuses prevent them.

-- Albert Einstein

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...