Csharp/C Sharp by API/System.Diagnostics/FileVersionInfo

Материал из .Net Framework эксперт
Перейти к: навигация, поиск

FileVersionInfo.CompanyName

 
using System;
using System.Diagnostics;
class MainClass {
    static void Main(string[] args) {
        FileVersionInfo info = FileVersionInfo.GetVersionInfo("c:\\a.txt");
        Console.WriteLine("Company Name: " + info.rupanyName);
    }
}


FileVersionInfo.FileDescription

 
using System;
using System.Diagnostics;
class MainClass {
    static void Main(string[] args) {
        FileVersionInfo info = FileVersionInfo.GetVersionInfo("c:\\a.txt");
        Console.WriteLine("File Description: " + info.FileDescription);
    }
}


FileVersionInfo.FileVersion

 
using System;
using System.Diagnostics;
class MainClass {
    static void Main(string[] args) {
        FileVersionInfo info = FileVersionInfo.GetVersionInfo("c:\\a.txt");
        Console.WriteLine("File Version: " + info.FileVersion);
    }
}


FileVersionInfo.GetVersionInfo

 
using System;
using System.Diagnostics;
class MainClass {
    static void Main(string[] args) {
        FileVersionInfo info = FileVersionInfo.GetVersionInfo("c:\\a.txt");
        Console.WriteLine("Checking File: " + info.FileName);
    }
}


FileVersionInfo.InternalName

 

using System;
using System.Diagnostics;
class MainClass {
    static void Main(string[] args) {
        FileVersionInfo info = FileVersionInfo.GetVersionInfo("c:\\a.txt");
        Console.WriteLine("InternalName: " + info.InternalName);
    }
}


FileVersionInfo.IsPatched

 
using System;
using System.Diagnostics;
class MainClass {
    static void Main(string[] args) {
        FileVersionInfo info = FileVersionInfo.GetVersionInfo("c:\\a.txt");
        Console.WriteLine("IsPatched: " + info.IsPatched);
    }
}


FileVersionInfo.LegalCopyright

 

using System;
using System.Diagnostics;
class MainClass {
    static void Main(string[] args) {
        FileVersionInfo info = FileVersionInfo.GetVersionInfo("c:\\a.txt");
        Console.WriteLine("Legal Copyright: " + info.LegalCopyright);
    }
}


FileVersionInfo.OriginalFilename

 
using System;
using System.Diagnostics;
class MainClass {
    static void Main(string[] args) {
        FileVersionInfo info = FileVersionInfo.GetVersionInfo("c:\\a.txt");
        Console.WriteLine("Original Filename: " + info.OriginalFilename);
    }
}


FileVersionInfo.ProductName

 

using System;
using System.Diagnostics;
class MainClass {
    static void Main(string[] args) {
        FileVersionInfo info = FileVersionInfo.GetVersionInfo("c:\\a.txt");
        Console.WriteLine("Product Name: " + info.ProductName);
    }
}


FileVersionInfo.ProductVersion

 

using System;
using System.Diagnostics;
class MainClass {
    static void Main(string[] args) {
        FileVersionInfo info = FileVersionInfo.GetVersionInfo("c:\\a.txt");
        Console.WriteLine("Product Version: " + info.ProductVersion);
    }
}