0

開発者環境で 1 つの Windows サービスを開発する必要があります。.Net Framework がインストールされていない Windows Server 2008 にサービスをインストールする必要があります。このシナリオに基づいて、Windows サービスをインストールする別の EXE ファイルを使用することにしました。

このコマンドを使用して、通常のコマンド プロンプトで Windows サービスをインストールできます。

c:\> sc create binpath = "my service path [EXE]"

しかし、このステートメントを別の EXE ファイルで実行する必要があります。このシナリオでより良い解決策はありますか。親切にこれを手伝ってください。

ありがとう、

4

1 に答える 1

0
if (the service is developed with .NET) {
    //do nothing and tell you manager that 
    //.net framework needs to be installed on Windows Server 2008
} else {
    //use the sc command or 
    //put the command in a batch file with conent "sc create binpath = "my service path [EXE]"
}
于 2012-11-23T04:45:03.427 に答える