Not sure why I can't get this to work. Running the output from the wscript.echo line on the command prompt works fine and outputs the text file. But doesn't within the script (doesn't create the text file). I'm pretty sure it has to do with the spaces in the path but since it works with copy...
Any one knwo if an AD object has a modified by attribute?
I see whenChanged, whenCreated attributes but would also like an attribute showing who last modified it or created it. Does that exist?
Thanks in advance.
Can some help me one how I can enumerate all user properties in AD instead of having to specify what I want like below? I'm looking for a specific value but also want to know the attributeName that is hold it. Thanks in advance.
objCommand.CommandText = "<" & strADsPath &...
I'm having a terrible time trying to format date/time from the installed software registry key (uninstall key) due to many formats being used.
Some example dates:
Fri Nov 02 19:20:55 CST 2007
9/18/2006
4-26-2004
Does anyone have ideas on how I can best do this? I need to format to a mysql...
Got a strange one that I can't get figured out. The script works great on several other machines but for some reason won't on one machine where I need to run it. I get the "Not enough server storage to process that command"
Thanks in advance.
The line it errors on is highlighted in red...
Can someone help me on how to get the systemdrive variable on a win2k box? I know how to do it on win2k3 using the win32_operatingsystem just can't get it figured out for a win2k box.
I have a for loop question on how to move to the next item if a condition is meant (Not Exit the for just move to the next item)
For i to Ubount(array)
if something = something Then
<----- Go to the next item in the for ----->
End if
Do other stuff here if...
Trying to kill a process but won't let me kill it. I'm an Administrator on the box, so I am at loss. Using the code below I am getting "Error code 2" when it tries to kill it. Please note I am only trying to kill notepad.exe as a test.
Thanks
intPID = 3204
strComputer = "server"...
I'm trying to retrieve what groups the computer object is a part of but I am having a issues. One when I run the script below I am getting this error:
"The directory property cannont be found in the cache." on this line 'strGroups = objComputer.GetEx("memberOf ")'
Second how can I run this...
I am trying to add a simple error handeling check in my script but doesn't seem to be working.
The script will work fine with servers that exist and don't cause error contitions but ones that would cause an error it doesn't seem to work.
Basicly I am testing to connect to a server that...
I am trying to write a script that will discovery hosts on a subnet but I am running into one problem. For some reason the line in red doesn't output anything to the logfile. But if I put the actual run statment into a command prompt it outputs fine.
Anyone have some ideas on why not...
Does anyone have any ideas on how to get the Network Driver and Duplex from all Network Cards on a NT4 box? I got it figured out for w2k/w2k3 but nt4 of course is way different.
Thanks for the suggestions.
--Todd
I am tring to enumerate values within a key in the registry. I am getting this error
Type mismatch: 'UBound' on line 12
Below is my code.
Thanks for the help
Const HKEY_LOCAL_MACHINE = &H80000002
Const REG_SZ = 1
strComputer = "."
Set objReg =...
Hopefully someone can help me out with this one. Basicly I am trying to export all the charts on one sheet. Here is my code but I am getting "Expected Statement" on Line 8 (mychart.Export Filename:="c:\charts\chart_" & i & ".gif", FilterName:="GIF")
Thanks for the help
Code
Set objXL =...
I am trying to write a simple script to get some information from a remote computer. But when I run it I get:
Permission denied: 'GetObject' (Line 9)
I am an administrator on the box. The box is a NT4 Server. and scripting host 5.6 is installed on the NT4 box. Any thoughts?
Thanks
--Todd...
Can someone tell me how I can escape quotes in a line?
Basicly I need the quotes around the directory since there is a space in it.
strCommand = "cacls "C:\Program Files\Program" /T /E /P Users:C"
Thanks
Does anyone know how to get the uptime of a machine like in mins or seconds? I was playing the the LastBootUpTime but can't see to get something figured out.
Thanks
Does anyone know how I can elevate some parts in a script to run as an admin. IE rebooting a remote machine and connecting to a remote registry. Below are the two things I need to do but need them to run as an admin
Set oReg=GetObject("winmgmts:{impersonationLevel=impersonate}!\\" &...
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.