⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 assemblyinfo.cs

📁 C sharp 调用WindowsAPI的平台调用例子
💻 CS
字号:
//Copyright (C) 2002 Microsoft Corporation
//All rights reserved.
//THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER 
//EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF 
//MERCHANTIBILITY AND/OR FITNESS FOR A PARTICULAR PURPOSE.
//Requires the Trial or Release version of Visual Studio .NET Professional (or greater).

using System;
using System.Reflection;

[assembly: AssemblyTitle("C# How-To: Win32 API Calls")]
[assembly: AssemblyDescription("Microsoft C# How-To: Win32 API Calls")]
[assembly: AssemblyCompany("Microsoft Corporation")]
[assembly: AssemblyProduct("Microsoft C# How To: 2002")]
[assembly: AssemblyCopyright("Copyright  2002 Microsoft Corporation.  All rights reserved.")]
[assembly: CLSCompliant(true)]
[assembly: AssemblyVersion("1.0.0.0")]

#region " Helper class to get information for the About form. "
// This class uses the System.Reflection.Assembly class to
// access assembly meta-data
// This class is not a normal feature of AssemblyInfo.cs

public class AssemblyInfo
{
	// Used by Helper Functions to access information from Assembly Attributes

	private Type myType;

	public AssemblyInfo() 
	{
		myType = typeof(frmMain);
	}

	public string AsmName {

		get {

			return myType.Assembly.GetName().Name.ToString();

		}

	}

	public string AsmFQName {

		get {

			return myType.Assembly.GetName().FullName.ToString();

		}

	}

	public string CodeBase {

		get {

			return myType.Assembly.CodeBase;

		}

	}

	public string Copyright {

		get {

			Type at = typeof(AssemblyCopyrightAttribute);

			object[] r = myType.Assembly.GetCustomAttributes(at, false);

			AssemblyCopyrightAttribute ct = (AssemblyCopyrightAttribute) r[0];

			return ct.Copyright;

		}

	}

	public string Company {

		get {

            Type at = typeof(AssemblyCompanyAttribute);

			object[] r = myType.Assembly.GetCustomAttributes(at, false);

			AssemblyCompanyAttribute ct = (AssemblyCompanyAttribute) r[0];

			return ct.Company;

		}

	}

	public string Description {

		get {

			Type at = typeof(AssemblyDescriptionAttribute);

			object[] r = myType.Assembly.GetCustomAttributes(at, false);

			AssemblyDescriptionAttribute da = (AssemblyDescriptionAttribute) r[0];

			return da.Description;

		}

	}

	public string Product {

		get {

			Type at = typeof(AssemblyProductAttribute);

			object[] r = myType.Assembly.GetCustomAttributes(at, false);

			AssemblyProductAttribute pt = (AssemblyProductAttribute) r[0];

			return pt.Product;

		}

	}

	public string Title {

		get {

			Type at = typeof(AssemblyTitleAttribute);

			object[] r = myType.Assembly.GetCustomAttributes(at, false);

			AssemblyTitleAttribute ta = (AssemblyTitleAttribute) r[0];

			return ta.Title;

		}

	}

	public string Version {

		get {

			return myType.Assembly.GetName().Version.ToString();

		}

	}

}

#endregion

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -