Hi, My error handling doesn't seem to be working:
sub backup (arrmem, backupdir)
err.clear
on error resume next
set objShell = CreateObject("shell.application")
set Shellfolder = objShell.NameSpace(backupdir)
shellfolder.CopyHere (arrmem), 272
if Err.number = 0 then
'happy days
else...
Hi I have a script which deletes the files and folders within subfolders of a folder. I need to delete all folders below objFolders (C:\scripts). Here it is:
strFolder = "C:\scripts"
intDays = 0
Set objFSO = CreateObject("Scripting.FileSystemObject")
Set objFolders =...
Hi I have a sub which copies files using shell.application and copyhere. It's working however I would like to get some error logging going for any files which dont copy. I've looked through the MSDN pages but there is nothing obvious so I have added my own but it doesnt work
sub backup...
Hi I have a WMI collection as below:
Set objSWbemLocator = CreateObject("WbemScripting.SWbemLocator")
if instr (strComputer, "localhost") then
Set objSWbemServices = objSWbemLocator.ConnectServer (strComputer, "root\WebAdministration", ms406)
else
Set objSWbemServices =...
Hi,
I have a script which pulls from IIS7 the application path, the application pool and the site name. The apppool comes from a different part of the WMI database so needs a different object to connect. Here is my code:
Const strInFile = "hostlist.txt"
Const ForReading = 1
Dim objFSO
Set...
Hi, I have a script which has an array containing file paths. I am going to use this array to prompt the user with the path and then get user interaction using an explorer browse folder to find a folder to backup the array path to.
Now, not all the paths in the array need backing up so is...
Hi,
I have a path which I need to trim down so that I have the last folder of it. The string I have is
c:\windows\system32\copyfolder.
I need to use \copyfolder as a variable elsewhere. I have looked at various functions but can seem to find anything which wors including Right, Left and...
Hi,
I have a script which puls info from WMI and creates an array with the returned information. The path information I am going to use to copy some remote files to but I need to exclude 1 particular file and copy the remaining files and folders. Here is my code so far:
Do Until...
Hi,
I have a script which I have compilled to collect some file paths. it uses set objShell = CreateObject("shell.application") and then copies files using these properties
shellfolder.CopyHere (arrmem), 20
I am getting an error on line 53 which says object required "shellfolder" but I know...
Hi,
I've been trying to remotely query using WMI an instance of IIS7. I've ritten the code which includes all the username and password but I am getting access denied.
Const strInFile = "hostlist.txt"
Const strOutFIle = "results.txt"
Const ForReading = 1
Const wbemFlagReturnImmediately =...
Hi,
I am trying to query an install of IIS 7 using VBscript and WMI but am having some problems. From what I can see there are e ways this is possible
1: IIS 7 WMI using XML
2: WMI using IIS 6
3: IIS 7 WMI
I'd like to use WMI IIS 7 and XML as the servers I will be working on only have this...
Hi,
I need to allow a different LAN connected but a different switch access through my outer to its trusted interface.
I am runnning a fairly complex VPN setup but currently dont have any access lists on the vlan1 interface
If I create an access list for the subnet and then aplly this to the...
Hi,
Does anyone know what I would need to purchase to backup a remote NAS to a tape drive using ACRServe?
There is a additional tape drive add on here: http://shop.arcserve.com/Products/Backup/R15-for-Windows-Tape-Library-Option
Does Arcserve do backup without this option
Thanks
James
Hi,
I have been using Openfiler iSCIS server and have experienced a corrupt volume and am unable to mount it. The data on there is really vauluable but I cant seem to get it iff.
I have tried several things including:
[root@localhost log]# mount -t ext3 /dev/dm-0 /media/test/
mount: wrong...
Hi,
I have written a script which finds files older than X moves them and then zips the file. For work I am trying to integrate a delete function which deletes the files after a successfully zipped. I have used error handling where wscript.shell catches the error from 7-zip.exe and if it's...
Hi,
Does anyone have any experience with RDPShell and powershell. I am running Windows 2008 RDS RemoteApps and have a requirement to upload a file from the client to the server.
Reading up on it Explorer is not used for RemoteApps but RDPShell.exe
Does anyone have any info in how I would be...
Hi,
I want to know if its possible to run a vbscript that prompts for a file location like explorer does.
I am going to try to upload a file from the computer where the file is run.
It gets complicated as the script wil run from a Windows Remote Desktop RemoteApp so will actually be running...
Hi I have set up some remote apps but need to stop people accessing the Remote desktop. I am running Server 2008 SP2 in 64bit mode but cant see anything int eh configuration.
I also see that suggested is running a program in TS profile to log the user off again. Also someone suggested...
Hi,
I have written some code but need to get the output gnerated to the actual HTA window and then incriment it as the script loops.
I have done so far the ping routine but only echoing a text box to screen, here it is:
<HTML>
<HEAD>
<HTA:Application
Border = Thick
BorderStyle =...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.