Module.FullyQualifiedName プロパティ

定義

このモジュールの完全修飾名とパスを表す文字列を取得します。

public:
 virtual property System::String ^ FullyQualifiedName { System::String ^ get(); };
public virtual string FullyQualifiedName { get; }
member this.FullyQualifiedName : string
Public Overridable ReadOnly Property FullyQualifiedName As String

プロパティ値

String

モジュールの完全修飾名。

例外

呼び出し元に、必要なアクセス許可がありません。

次の例では、指定したモジュールの完全修飾名を表示します。

using namespace System;
using namespace System::Reflection;
int main()
{
   array<Module^>^moduleArray;
   moduleArray = Assembly::GetExecutingAssembly()->GetModules( false );
   
   // In a simple project with only one module, the module at index
   // 0 will be the module containing this class.
   Module^ myModule = moduleArray[ 0 ];
   Console::WriteLine( "myModule.FullyQualifiedName = {0}", myModule->FullyQualifiedName );
}
using System;
using System.Reflection;

namespace ReflectionModule_Examples
{
    class MyMainClass
    {
        static void Main()
        {
            Module[] moduleArray;
            
            moduleArray = typeof(MyMainClass).Assembly.GetModules(false);
            
            // In a simple project with only one module, the module at index
            // 0 will be the module containing this class.
            Module myModule = moduleArray[0];

            Console.WriteLine("myModule.FullyQualifiedName = {0}", myModule.FullyQualifiedName);
        }
    }
}
Imports System.Reflection

Namespace ReflectionModule_Examples
    Class MyMainClass
        Shared Sub Main()
            Dim moduleArray() As [Module]

            moduleArray = GetType(MyMainClass).Assembly.GetModules(False)

            ' In a simple project with only one module, the module at index
            ' 0 will be the module containing this class.
            Dim myModule As [Module] = moduleArray(0)

            Console.WriteLine("myModule.FullyQualifiedName = {0}", myModule.FullyQualifiedName)
        End Sub
    End Class
End Namespace 'ReflectionModule_Examples

注釈

パスを指定せずに名前を取得するには、次を使用 Nameします。

このモジュールのアセンブリがバイト配列から読み込まれた場合、 FullyQualifiedName モジュールのアセンブリは次のようになります <Unknown>。

注意

モジュール名の大文字と小文字はプラットフォームに依存します。

適用対象