共用方式為


HOW TO:設定應用程式的啟動類型

此範例示範如何將啟動型別設為 "server"。

範例

Imports System.EnterpriseServices
< assembly: ApplicationActivation(ActivationOption.Server)>
Public Class Account 
Inherits ServicedComponent
   Shared Sub Main()
   End Sub
End Class
using System.EnterpriseServices;
[ assembly: ApplicationActivation(ActivationOption.Server)] 
public class Account : ServicedComponent
{
   static void Main() {}
}

編譯程式碼

這個範例需要:

請參閱

參考

System.EnterpriseServices

概念

註冊 Serviced 元件

Footer image

Copyright © 2007 by Microsoft Corporation. All rights reserved.