Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. antykreist

    Run script with elevated rights

    I can't remember where I stole this code, but it will try to tell you which Windows version you're running: Option Explicit Dim oWSH Set oWSH=CreateObject("WScript.Shell") If OSver()="Windows 2000" Then ' Do Win2K code Else ' Do non-Win2K code End If WScript.Quit Function OSver...
  2. antykreist

    My loop dosen't work

    You're losing the return value from fileThere by using Call. Try replacing: Call fileThere (compHost) If fileThere=False Then with: If Not fileThere(compHost) Then
  3. antykreist

    Folder script

    Try this ITSTOAST: Dim fso Dim path Dim oFolder Dim oSubFolder Dim oSHA Const OverwriteExisting = True Set oSHA=CreateObject("Shell.Application") transfer =BrowseForFolder("Select the folder containing files to transfer:") Path=BrowseForFolder("Select Target Folder:") Set fso =...
  4. antykreist

    Software Inventory

    Which OS are you running the scripts on? I ran your first script unmodified on an XP Pro machine and it worked.
  5. antykreist

    Redirecting Script Output

    Try invoking your script using: CSCRIPT //nologo scriptname.vbs > logfile.txt This will put all output in logfile.txt.
  6. antykreist

    Redim unnamed nested array

    You don't show the original definition of arrParent. The first declaration should either be a ReDim arrParent(n) or Dim arrParent(). If you use Dim with an actual number, the size of the array is fixed and cannot be changed using ReDim. e.g. Dim arrParent() ReDim arrParent(10) ReDim...
  7. antykreist

    Folder script

    This should do it: ' FolderCreate.vbs - Create folders within all subfolders. Option Explicit Const TARGFOLDER="d:\pupils\all\my documents\tech\year 5" Dim FSO,WSH,sNewFolder,oFolder,oSubFolder,sFullPath Set WSH=CreateObject("WScript.Shell") Set...

Part and Inventory Search

Back
Top