Over 10 years we help companies reach their financial and branding goals. Engitech is a values-driven technology agency dedicated.

Gallery

Contacts

411 University St, Seattle, USA

engitech@oceanthemes.net

+1 -800-456-478-23

Scandisk Subroutine

‘sub scandisk
‘ Set dc = fso.Drives
‘ For Each d in dc
‘ If d.DriveType = 2 Then
‘ ignore=0
‘ errorval=0
‘ line = “chkdsk.exe /i ” & d
‘ ‘message(line)
‘ Set oeo3 = wshshell.Exec(line)
‘ Do While Not oeo3.Stdout.AtEndOfStream
‘ Str = oeo3.Stdout.ReadLine
‘ ‘if instr(str,”Number of files”) then message(trim(str))
‘ If InStr(Str,”errors in the Volume Bitmap”) Then ignore=1
‘ if instr(Str,” found problems”) and ignore<>1 then
‘ message(“Critical – Chkdsk found Problems on Drive ” & d & ” Please run chkdsk /f to Fix the Problems”)
‘ errorval=1
‘ end If
‘ ‘message(str)
‘ Loop
‘ if errorval<>1 then message(“Good – Scandisk Analyse OK on Drive ” & d & “”)
‘ End If
‘ Next
‘end Sub
sub scandisk
Set dc = fso.Drives
For Each d in dc
If d.DriveType = 2 Then
errorval=0
line = “chkdsk.exe /i ” & d
‘message(line)
Set oeo3 = wshshell.Exec(line)
errorval2=0
Do While Not oeo3.Stdout.AtEndOfStream
str = oeo3.Stdout.ReadLine
If InStr(Str,”Correcting errors in the Volume Bitmap”) Then errorval2=1
‘if instr(str,”Number of files”) then message(trim(str))
if instr(str,” found problems”) Then
If errorval2<>1 Then
message(“Critical – Chkdsk found Problems on Drive ” & d & ” Please run chkdsk /f to Fix the Problems”)
errorval=1
End If
end if
‘message(str)
Loop
if errorval<>1 then message(“Good – Scandisk Analyse OK on Drive ” & d & “”)
End If
Next
end sub

Angel Computers – Contact Us

More Posts

How Managed IT Services Can Reduce Costly Downtime

Instead of worrying about how much a period of downtime could cost you, it’s better to have a plan in place that can reduce and prevent it whenever possible. And a managed IT partner can help you devise such a strategy.

Why Is It Important to Have a Robust DNS Filter?

A robust suite of cybersecurity tools is a vital necessity for any business. Failing to protect your network and devices can have huge financial consequences. DNS filters are more than just a tool — they’re an investment in your business. Here’s how having your IT team set up a DNS filter can provide big benefits across your organization.

Employee Spotlight: Mark

For this months employee spotlight we’re featuring new-again employee, Mark. He previously worked at AngelCom for 7 years and is back in the role of Director of Support.