Import Namespace

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • moondaddy

    Import Namespace

    In vb.net its possible import a namespace into a project so you don't need
    to add it to the top of every class. Is there a way to do this in c# on a
    project level?


  • Sayed Ibrahim Hashimi

    #2
    RE: Import Namespace

    Not really available for the entire project. But you can place the using
    statement within the namespace. Doing so, you won't have to repeat that
    statement anywhere else in the namespace. See the last example at


    Generally i prefer to place the using directive at the very top of the file,
    outside of the namespace, but that's up to you :)

    Sayed Ibrahim Hashimi
    John Doe is a professional web developer. He is blogging about ASP.NET and web developing.



    "moondaddy" wrote:
    [color=blue]
    > In vb.net its possible import a namespace into a project so you don't need
    > to add it to the top of every class. Is there a way to do this in c# on a
    > project level?
    >
    >
    >[/color]

    Comment

    Working...