HOW TO:將 ApplicationID 屬性套用到組件
這個範例示範如何將 ApplicationID 屬性套用至組件。
範例
Imports System.EnterpriseServices
<assembly: ApplicationName("BankComponent")>
< assembly: ApplicationID("4fb2d46f-efc8-4643-bcd0-6e5bfa6a174c")>
Public Class Account
Inherits ServicedComponent
Shared Sub Main()
End Sub
End Class
using System.EnterpriseServices;
[ assembly: ApplicationName("BankComponent")]
[ assembly: ApplicationID("4fb2d46f-efc8-4643-bcd0-6e5bfa6a174c")]
public class Account : ServicedComponent
{
static void Main() {}
}
編譯程式碼
這個範例需要:
- 參考 System 和 System.EnterpriseServices 命名空間
請參閱
參考
概念
Copyright © 2007 by Microsoft Corporation. All rights reserved.