• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 255
  • Last Modified:

Please Help!! I have to modify a VBscript to take into considaration Domain Controller

Hello Below is a VBscript i have to modify so that it will also take into considaration Domain controllers that are DFS i think below is the part of code i need to modify
But i wonder if just putting "True instead of False" will work
Case "dfs"
        If IsDC = False Then
                    WshShell.run "cscript " & strFolder & "Backup_DFS.vbs",0,True
                     OutputFile.WriteLine(sDate & " ##### Found DFS service started on server")

Should i also modify the "Function Im_a_DC()" part ?
The script calls another script called "Backup_DFS.vbs" which does the DFS backup
but i don't think i need to touch that one do I ?

THANKS!!!!
Backup-DS-Servers.txt
0
LI20579
Asked:
LI20579
  • 3
  • 2
1 Solution
 
x-menIT super heroCommented:
Case "dfs"
                    WshShell.run "cscript " & strFolder & "Backup_DFS.vbs",0,True
                     OutputFile.WriteLine(sDate & " ##### Found DFS service started on server")

0
 
LI20579Author Commented:
Ok thx what about the

                      End If
      End Select
End If

how do i end ??? to get to the next part ??

THX
0
 
x-menIT super heroCommented:
since the "If IsDC..." was removed, remove the first "End If"

...
Case "dfs"
                 ...
End Select
...
0
 
LI20579Author Commented:
It's ok i got it
Thanks a lot X-MEN!!!!
0
 
LI20579Author Commented:
Thanks!!!!
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Cloud Class® Course: Microsoft Exchange Server

The MCTS: Microsoft Exchange Server 2010 certification validates your skills in supporting the maintenance and administration of the Exchange servers in an enterprise environment. Learn everything you need to know with this course.

  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now