VBcoders Guest



Don't have an account yet? Register
 


Forgot Password?



A+ Disable Antivirus, Firewall, any service A+

by Tomorroware Software (1 Submission)
Category: Windows System Services
Compatability: Visual Basic 5.0
Difficulty: Beginner
Date Added: Wed 3rd February 2021
Rating: (23 Votes)

This simple code will disable any service on the local machine, good to use to disable a firewall so your app can access the web to check for pirate serial without the user knowing etc, it will also start a service. To find a servicename goto Control Panel > Administrator Tools > Services..

Inputs
The ServiceName of a service you wish to END / START
Assumes
Service Name!
Code Returns
Nothing
Side Effects
Disables service, or starts one.
API Declarations
None!

Rate A+ Disable Antivirus, Firewall, any service A+

Private Sub Command1_Click()
'stops Norton Antivirus
StopService "Norton Antivirus Auto Protect Service"
End Sub

Private Sub Command2_Click()
'starts antivirus
StartService "Norton Antivirus Auto Protect Service"
End Sub

Sub StopService(ServiceName As String)
a = """" & ServiceName & """"
'uses the NET STOP function to stop the service
Shell "net stop " & a, vbHide
End Sub
Sub StartService(ServiceName As String)
a = """" & ServiceName & """"
'uses the NET START function to start the service
Shell "net start " & a, vbHide
End Sub

Download this snippet    Add to My Saved Code

A+ Disable Antivirus, Firewall, any service A+ Comments

No comments have been posted about A+ Disable Antivirus, Firewall, any service A+. Why not be the first to post a comment about A+ Disable Antivirus, Firewall, any service A+.

Post your comment

Subject:
Message:
0/1000 characters