home *** CD-ROM | disk | FTP | other *** search
- VERSION 5.00
- Object = "{5DA62B65-0D48-11D2-A6E3-00400541EFEE}#1.0#0"; "SvcIt.ocx"
- Begin VB.Form Admin
- BorderStyle = 3 'Fixed Dialog
- Caption = "Service Admin"
- ClientHeight = 1695
- ClientLeft = 150
- ClientTop = 435
- ClientWidth = 3255
- LinkTopic = "Form2"
- MaxButton = 0 'False
- MinButton = 0 'False
- ScaleHeight = 1695
- ScaleWidth = 3255
- ShowInTaskbar = 0 'False
- StartUpPosition = 1 'CenterOwner
- Begin VB.CommandButton CmdContinue
- Caption = "Continue"
- Height = 315
- Left = 2040
- TabIndex = 6
- Top = 1320
- Width = 1065
- End
- Begin VB.CommandButton CmdStart
- Caption = "Start"
- Height = 315
- Left = 2040
- TabIndex = 5
- Top = 150
- Width = 1065
- End
- Begin VB.CommandButton CmdStop
- Caption = "Stop"
- Height = 315
- Left = 2040
- TabIndex = 4
- Top = 540
- Width = 1065
- End
- Begin VB.CommandButton CmdPause
- Caption = "Pause"
- Height = 315
- Left = 2040
- TabIndex = 3
- Top = 930
- Width = 1065
- End
- Begin VB.CommandButton CmdRemove
- Caption = "Remove"
- Height = 315
- Left = 780
- TabIndex = 2
- Top = 540
- Width = 1065
- End
- Begin VB.CommandButton CmdInstall
- Caption = "Install"
- Height = 315
- Left = 780
- TabIndex = 1
- Top = 150
- Width = 1065
- End
- Begin SVCITLib.SvcIt MyService
- Height = 480
- Left = 180
- TabIndex = 0
- Top = 180
- Width = 480
- _Version = 65536
- _ExtentX = 847
- _ExtentY = 847
- _StockProps = 0
- ServiceName = "BeepService"
- DisplayName = "Service-It Sample Beep Service"
- Dependencies = "LanmanWorkstation"
- MachineName = ""
- ServiceExe = ""
- Mode = 2
- End
- Attribute VB_Name = "Admin"
- Attribute VB_GlobalNameSpace = False
- Attribute VB_Creatable = False
- Attribute VB_PredeclaredId = True
- Attribute VB_Exposed = False
- Option Explicit
- Private Sub CmdContinue_Click()
- If MyService.IsPaused Then
- MyService.Continue
- End If
- End Sub
- Private Sub CmdInstall_Click()
- If MyService.IsInstalled Then
- ' Remove previous service entry
- MyService.Remove
- End If
- ' Install and start the service
- MyService.Install True
- End Sub
- Private Sub CmdPause_Click()
- If MyService.IsRunning Then
- MyService.Pause
- End If
- End Sub
- Private Sub CmdRemove_Click()
- If MyService.IsInstalled Then
- MyService.Remove
- End If
- End Sub
- Private Sub CmdStart_Click()
- MyService.Start ("")
- End Sub
- Private Sub CmdStop_Click()
- If MyService.IsRunning Or MyService.IsPaused Then
- MyService.Stop
- End If
- End Sub
- Private Sub Command1_Click()
- End Sub
-