Click here to Skip to main content
15,898,538 members
Home / Discussions / Visual Basic
   

Visual Basic

 
AnswerRe: Detecting disconnection from database Pin
Tom Deketelaere22-Sep-10 3:57
professionalTom Deketelaere22-Sep-10 3:57 
QuestionRe: Detecting disconnection from database Pin
Eddy Vluggen22-Sep-10 9:17
professionalEddy Vluggen22-Sep-10 9:17 
AnswerRe: Detecting disconnection from database Pin
chrispowell1234523-Sep-10 0:02
chrispowell1234523-Sep-10 0:02 
GeneralRe: Detecting disconnection from database Pin
Dave Kreskowiak23-Sep-10 2:01
mveDave Kreskowiak23-Sep-10 2:01 
GeneralRe: Detecting disconnection from database Pin
chrispowell1234523-Sep-10 2:35
chrispowell1234523-Sep-10 2:35 
GeneralRe: Detecting disconnection from database Pin
Ian Shlasko23-Sep-10 2:58
Ian Shlasko23-Sep-10 2:58 
GeneralRe: Detecting disconnection from database [modified] Pin
Dave Kreskowiak23-Sep-10 5:28
mveDave Kreskowiak23-Sep-10 5:28 
QuestionVBScript - Gathering WMI & Registry information from networked computers - SOLVED [modified] Pin
eeffoc4221-Sep-10 4:30
eeffoc4221-Sep-10 4:30 
I've been working on a script that will collect information from the computers on our network.

First I generated a list of computer names by getting the information from Active Directory and put it into a text file

Second I've got a script that will go through the list of computer names and gather the information and put it into a .csv file.

So far everything is working just fine except for when I need to read information from the registry.

I get all the correct information for the WMI stuff for each computer but for the registry information, what I get is the information from the computer running the script rather than the remote computer.

What I need help with is modifying the code so I can access the registry on the remote computers.

		Next
			
		' Now get all the Monitor Info
		objOutputFile.Write ", ," & GetMonitorInfo() & vbNewLine
							
	Else
		'WScript.Echo strComputer & " not found..."
		objOutputFile.Write "*** " & strComputer & " *** NOT Found" & vbCrLf
		Err.Clear
		End If
	Next
	
	
	End If

End If

End Sub


'DISPLAY_REGKEY sets the regkey where displays are found. Don't change except for debugging
'I only change it when I am looking at a .REG file that someone sent me saying that the
'code doesn't work.
	Const DISPLAY_REGKEY="HKLM\SYSTEM\CurrentControlSet\Enum\DISPLAY\"
'sets the debug outfile (use format like c:\debug.txt)
	Const DEBUGFILE="NUL"
'if set to 1 then output debug info to DEBUGFILE (also writes debug to screen if running under cscript.exe)
	Const DEBUGMODE=0
'The ForceCscript subroutine forces execution under CSCRIPT.EXE/Prevents execution
'under WSCRIPT.EXE -- useful when debugging
'ForceCScript
 
	DebugOut "Execution Started " & cstr(now)
'wscript.echo GetMonitorInfo() 'just write the output to screen
	DebugOut "Execution Completed " & cstr(now)
 
'This is the main function. It calls everything else
'in the correct order.
Function GetMonitorInfo()
 
	debugout "Getting all display devices"
	arrAllDisplays=GetAllDisplayDevicesInReg()
	debugout "Filtering display devices to monitors"
	arrAllMonitors=GetAllMonitorsFromAllDisplays(arrAllDisplays)
	debugout "Filtering monitors to active monitors"
	arrActiveMonitors=GetActiveMonitorsFromAllMonitors(arrAllMonitors)
 
	if ubound(arrActiveMonitors)=0 and arrActiveMonitors(0)="{ERROR}" Then
		debugout "No active monitors found"
		strFormattedMonitorInfo="[Monitor_1]" & vbcrlf & "Monitor=Not Found" & vbcrlf & vbcrlf
	else
		debugout "Found active monitors"
		debugout "Retrieving EDID for all active monitors"
		arrActiveEDID=GetEDIDFromActiveMonitors(arrActiveMonitors)
		debugout "Parsing EDID/Windows data"
		arrParsedMonitorInfo=GetParsedMonitorInfo(arrActiveEDID,arrActiveMonitors)
		debugout "Formatting parsed data"
		strFormattedMonitorInfo=GetFormattedMonitorInfo(arrParsedMonitorInfo)
	end If


Here is a link to the full code:
http://pastebin.com/n3JRYdUP[^]
AnswerRe: VBScript - Gathering WMI & Registry information from networked computers Pin
Dave Kreskowiak21-Sep-10 6:32
mveDave Kreskowiak21-Sep-10 6:32 
AnswerRe: VBScript - Gathering WMI & Registry information from networked computers Pin
Eddy Vluggen22-Sep-10 9:21
professionalEddy Vluggen22-Sep-10 9:21 
QuestionRe: VBScript - Gathering WMI & Registry information from networked computers - SOLVED Pin
Member 330175419-Jan-11 6:57
Member 330175419-Jan-11 6:57 
Questionbroadcasting data using UDP winsocket control... [modified] Pin
jainiraj20-Sep-10 2:28
jainiraj20-Sep-10 2:28 
AnswerRe: broadcasting data using UDP winsocket control... Pin
DaveAuld20-Sep-10 11:00
professionalDaveAuld20-Sep-10 11:00 
GeneralRe: broadcasting data using UDP winsocket control... Pin
jainiraj20-Sep-10 18:50
jainiraj20-Sep-10 18:50 
GeneralRe: broadcasting data using UDP winsocket control... Pin
DaveAuld20-Sep-10 21:50
professionalDaveAuld20-Sep-10 21:50 
GeneralRe: broadcasting data using UDP winsocket control... Pin
jainiraj21-Sep-10 3:06
jainiraj21-Sep-10 3:06 
GeneralRe: broadcasting data using UDP winsocket control... Pin
DaveAuld21-Sep-10 3:46
professionalDaveAuld21-Sep-10 3:46 
Questioncut print tasks Pin
JR21219-Sep-10 20:40
JR21219-Sep-10 20:40 
AnswerRe: cut print tasks Pin
DaveAuld20-Sep-10 10:26
professionalDaveAuld20-Sep-10 10:26 
GeneralRe: cut print tasks Pin
JR21220-Sep-10 19:16
JR21220-Sep-10 19:16 
AnswerRe: cut print tasks Pin
_Damian S_20-Sep-10 20:47
professional_Damian S_20-Sep-10 20:47 
GeneralRe: cut print tasks Pin
JR21220-Sep-10 20:52
JR21220-Sep-10 20:52 
Questionchange databases Pin
Member 320653117-Sep-10 12:49
Member 320653117-Sep-10 12:49 
AnswerRe: change databases Pin
Henry Minute17-Sep-10 14:29
Henry Minute17-Sep-10 14:29 
GeneralRe: change databases Pin
Member 320653117-Sep-10 16:42
Member 320653117-Sep-10 16:42 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.