Aliasing / Shortening the Namespaces in .NET

前端 未结 2 860
余生分开走
余生分开走 2021-01-08 01:14

There are two namespaces with class Image. One is iTextSharp and another WPF System.Windows.Control.Image.

Now I\'ve to use complete refere

相关标签:
2条回答
  • 2021-01-08 01:42

    Try:

    using yourAlias = System.Windows.Control.Image;
    
    0 讨论(0)
  • 2021-01-08 01:46

    Yeps, just use:

    using Img = System.Windows.Control.Image;
    

    In your namespace declaration.

    Then you can use the Img aliased name as you used the fully qualified name previously.

    0 讨论(0)
提交回复
热议问题