Search found 182 matches

by rasimmer
Wed Aug 11, 2010 7:38 am
Forum: Other Scripting Languages
Topic: HTA/VBS Noob question
Replies: 29
Views: 19703

HTA/VBS Noob question

You can do it all in the HTA. The whole point of using a HTA over vbScript is that you can use HTML form controls to gatherdisplay information to be used in the script (like InputBox). The script below is something I wrote a couple years ago to update the "ManagedBy" attribute on computer accounts. ...
by rasimmer
Tue Jul 27, 2010 6:58 am
Forum: VBScript
Topic: Searching/parsing a .csv file
Replies: 8
Views: 2725

Searching/parsing a .csv file

Const FOR_READING = 1Dim objFSO : Set objFSO = CreateObject("Scripting.FileSystemObject")Dim colFiles : Set colFiles = objFSO.GetFolder("C:Tick_Folder").FilesDim objFileFor Each objFile in colFiles If InStr(UCase(objFile.Name), "TICK") Then Dim objTextStream : Set objTextStream = objFile.OpenAsTextS...
by rasimmer
Thu Jul 22, 2010 12:45 am
Forum: VBScript
Topic: Can I log System IP Using any script..!
Replies: 2
Views: 1122

Can I log System IP Using any script..!

There isn't anything logged by default for something such as this. You can look at WMI Event Sinks to capture events such as deleting a file from a folder and return information about the event: http://msdn.microsoft.com/en-us/library/aa393013(VS.85).aspx http://msdn.microsoft.com/en-us/library/aa39...
by rasimmer
Tue Jun 22, 2010 7:33 am
Forum: VBScript
Topic: CDO.Message is lying to me..
Replies: 6
Views: 2219

CDO.Message is lying to me..

Good catch JVierra, I didn't see the =
by rasimmer
Tue Jun 22, 2010 5:59 am
Forum: Other Scripting Languages
Topic: Request Type Mismatch error
Replies: 3
Views: 3972

Request Type Mismatch error

Is it GetObjectByID or GetElementByID?
by rasimmer
Wed May 19, 2010 6:57 am
Forum: VBScript
Topic: Question about Ping Function..
Replies: 4
Views: 1195

Question about Ping Function..

Function blnPing(device_name) blnPing = False Dim colItems : Set colItems = GetObject("winmgmts:rootcimv2").ExecQuery &_ ("Select StatusCode from Win32_PingStatus Where Address = '" & device_name & "'") Dim objItem For Each objItem in colItems If objItem.StatusCode = 0 Then blnPing = True NextEnd Fu...
by rasimmer
Mon May 17, 2010 2:11 am
Forum: VBScript
Topic: Removing Trailing Spaces from Input Txt File
Replies: 3
Views: 1226

Removing Trailing Spaces from Input Txt File

Per JVierra's suggestion, this should work with his example:

strComputer = Trim(Replace(File.ReadLine, vbTab, ""))
by rasimmer
Fri May 14, 2010 1:11 am
Forum: VBScript
Topic: Permission denied: 'GetObject' in Windows 7
Replies: 9
Views: 4838

Permission denied: 'GetObject' in Windows 7

I guess the question is HOW did the DCOM permissions get turned off, which I'm sure it's not by default turned off.
by rasimmer
Thu May 13, 2010 1:20 am
Forum: VBScript
Topic: Printing in VBscript
Replies: 4
Views: 4051

Printing in VBscript

Some printer setting are driver driven, so you may not be able to access it via WMI. Sometimes vendors will provide an EXE that you can pass CMD line parameters to the printer. The simplest method, assuming you have a network print server and would like the setting set globally, is to just do it at ...
by rasimmer
Mon May 10, 2010 4:08 am
Forum: VBScript
Topic: Permission denied: 'GetObject' in Windows 7
Replies: 9
Views: 4838

Permission denied: 'GetObject' in Windows 7

Windows or 3rd party firewall?