This VBS script will allow you to send your Active Directory (AD) System System Management Container information to excel for your documentation and refrence.
Note: Other system containers such as your File Replication Service, IP Security and MicrosoftDNS containers can be accessed as well by changing the strContainer value from CN=System Management to CN=IP Security for example.
VBS Script:
strContainer = "CN=System Management,CN=System,"
Set objExcel = CreateObject("Excel.Application")
objExcel.Visible = True
objExcel.Workbooks.Add
intRow = 2
objExcel.Cells(1, 1).Value = "Name"
objExcel.Cells(1, 2).Value = "Type"
objExcel.Cells(1, 3).Value = "Description"
Set objDomain = GetObject("LDAP://RootDSE")
Set objContainer = GetObject("LDAP://" & strContainer & objDomain.Get("defaultNamingContext"))
For Each objChild In objContainer
Set objClass = GetObject(objChild.Schema)
If objClass.Container = True Then
objExcel.Cells(intRow, 1).Value = objChild.Name
objExcel.Cells(intRow, 2).Value = objChild.Class
objExcel.Cells(intRow, 3).Value = objChild.Description
Else
End If
intRow = intRow + 1
Next
objExcel.Range("A1:C1").Select
objExcel.Selection.Font.ColorIndex = 11
objExcel.Selection.Font.Bold = True
objExcel.Range("A1").Select
objExcel.Cells.EntireColumn.AutoFit
Set objSheet = objExcel.ActiveWorkbook.Worksheets(1)
Set objRange = objExcel.Range("A1")
objRange.Sort objRange,1,,,,,,1
MsgBox "Done"
Provided here is a VBS script version of the Asset Intelligence asset intelligence reports report.
strComputer = InputBox ("Enter Site Server Name")
strSiteCode = InputBox ("Enter Site Code")
objExcel.Cells(1, 2).Value = "Category"
objExcel.Cells(1, 3).Value = "Report ID"
Set objWMIService = GetObject("winmgmts://" & strComputer & "\root\sms\site_" & strSiteCode)
Set colItems = objWMIService.ExecQuery("Select * from SMS_Report Where Category = 'Asset Intelligence'")
For Each objItem in colItems
objExcel.Cells(intRow, 1).Value = objItem.Name
objExcel.Cells(intRow, 2).Value = objItem.Category
objExcel.Cells(intRow, 3).Value = objItem.ReportID
objExcel.Selection.Interior.ColorIndex = 19
Provided here is a SQL version of the Asset Intelligence inventoried software titles all inventoried software titles report.
SQL Query:
Select
CommonName 'Product Name',
IsNull(CommonPublisher, '') Vendor,
IsNull(CommonVersion, '') Version,
CategoryName Category,
FamilyName 'Family Name',
IsNull(Tag1Name, '') 'Label 1',
IsNull(Tag2Name, '') 'Label 2',
IsNull(Tag3Name, '') 'Label 3',
'State' = Case
When State = 4 Then 'Uncategorized'
Else 'Validated'
End
From v_LU_SoftwareList_Editable
Order by CommonName
Provided here is a SQL version of the Asset Intelligence customized catalog software families report.
CategoryName Name,
Description,
'Type' = Case
When Type = 1 Then 'Validated'
From v_LU_Category_Editable
Where Type = 1
Order by CategoryName
Errol Flynn was quite the ladies man according to the newspapers and tabloids of his day. During World War II servicemen fist coined “In like Flynn” when they were bragging about their own conquests or to it was used to describe someone with those gifts that they envied.
Today we use the term to do the same as they did back in the 1940’s.
This free Remote Desktop Enabler utility from IntelliAdmin allows to you enable the remote desktop feature of Windows XP and later machines remotely. The utility is useful for enabling Remote Desktop on machines where you forgot to enable connectivity and cannot get the machines physically.
RDP Remote Desktop Enabler
http://www.intelliadmin.com/RDPRemoteEnabler_Free.exe
Screen Print
http://www.mydigitallife.info/wp-content/uploads/2008/06/remote-desktop-enabler-268x300.jpg
Provided here is an HTA script that will allow you to start a Remote Desktop connection to a specified machine by selecting or choosing the machine name from a list of radio boxes.
Note: This script only uses the Full Screen (/F) switch however you can use any of the other following switches in its place or in addition to it:
“Connection File”
/Console
/Admin
/W:xxx
/H:xxx
/Public
/Span
/Edit
/Migrate
For a complete list of available remote desktop connection usage switches from the Run line enter: Mstsc /?
Tip: On the line(s) that read:
<input type="radio" name="RadioOption" value="ServerOne">Server One<BR>
You can change the value="ServerOne" to the machines IP address if needed or you can change the Server One machine name value to a more descriptive name such as in the example below:
<input type="radio" name="RadioOption" value="SMS001">Primary<BR>
<input type="radio" name="RadioOption" value="SMS002">Secondary<BR>
HTA Script:
<Html>
<Head>
<Title>Remote Desktop Chooser</Title>
<Style>
Body {Background-Color: CornSilk}
</Style>
<HTA:Application
Caption = Yes
Border = Thick
Scroll = No
ShowInTaskBar = No
MaximizeButton = Yes
MinimizeButton = Yes>
<script Language = VBScript>
Sub Window_OnLoad
Window.ResizeTo 400,250
End Sub
Sub WindowsLoad
For Each objButton in RadioOption
If objButton.Checked Then
Set wshShell = CreateObject("WScript.Shell")
WshShell.Run "Mstsc /V " & objButton.Value & " /F"
Self.Close()
</script><Body>
<p><h3 align = center><font color='Orange'>Please Visit myITforum.Com</font></h3>
<div></div>
<table align='center'>
<input type="radio" name="RadioOption" value="ServerTwo">Server Two<BR>
<input type="radio" name="RadioOption" value="ServerThree">Server Three<P>
<input id=runbutton class="button" type="button" value="Run Script" name="run_button" onClick="WindowsLoad">
<Span Id = "DataArea"></Span></Body><Div Align = "Center">
<P><A Href="http://myitforum.com/cs2/blogs/dhite">Created For myITforum By Don Hite</A>
This By Request VBS script will start the Hearts Game form a Local machine.
Set objShell = createobject("wscript.shell")
strCommand = "MsHearts.Exe"
objShell.run strCommand, 1, True
Learn the weird histories and bizarre facts behind these products.
http://www.wackyuses.com/weird.html
Discover hundreds of little-known uses for well-known products,
by just clicking on a product!
http://www.wackyuses.com/uses.html
This VBS Script will allow you to enter a site server name and site code and will write all of the resource names found to an Excel spreadsheet and if the resources are not clients the results will be written in red.
objExcel.Cells(1, 1).Value = "Machine Name"
objExcel.Cells(1, 2).Value = "Client"
Set colItems = objWMIService.ExecQuery ("Select * From SMS_R_System")
If objItem.Client = 1 Then
objExcel.Cells(intRow, 2).Value = "Yes"
objExcel.Cells(intRow, 2).Value = "No"
If objExcel.Cells(intRow, 2).Value = "No" Then
objExcel.Cells(intRow, 1).Font.ColorIndex = 3
objExcel.Cells(intRow, 2).Font.ColorIndex = 3
objExcel.Range("A1:B1").Select
This Vbs script will prompt you for a machine name and then return the parent Organizational Unit (OU) that it belongs to.
Note: Be sure to change Your_DC_Name to your DC name in the line that reads:
'LDAP://dc=Your_Dc_Name,dc=com' WHERE objectCategory = 'computer' " _
Vbs Script:
Const ADS_SCOPE_SUBTREE = 2
strComputer = InputBox("Enter Machine Name")
Set objConnection = CreateObject("ADODB.Connection")
Set objCommand = CreateObject("ADODB.Command")
objConnection.Provider = "ADsDSOObject"
objConnection.Open "Active Directory Provider"
Set objCommand.ActiveConnection = objConnection
objCommand.Properties("Page Size") = 1000
objCommand.Properties("Searchscope") = ADS_SCOPE_SUBTREE
On Error Resume Next
objCommand.CommandText = "Select ADsPath From 'LDAP://dc=Your_Dc_Name,dc=com' WHERE objectCategory = 'computer' " _
& "AND name='" & strcomputer & "'"
Set objRecordSet = objCommand.Execute
objRecordSet.MoveFirst
Do Until objRecordSet.EOF
strResult = objRecordSet.Fields("ADsPath").Value
objRecordSet.MoveNext
Loop
If strResult <> "" Then
Wscript.Echo "The Parent OU For " & UCase(strComputer) & " is: " & strResult
Wscript.Echo "The Machine Was Not Found"
This VBS script will prompt you for a site server name, site code and inbox and will count the files in the specified inbox and send the results to an Excel spreadsheet.
strSiteServer = InputBox ("Enter Site Server Name")
strInbox = InputBox ("Enter InBox Name",, "CcrRetry.Box")
objGetPath = "\\" & strSiteServer & "\SMS_" & strSiteCode & "\Inboxes\" & strInbox
Set oFSO = CreateObject("Scripting.FileSystemObject")
objExcel.Cells(1, 1).Value = "Site Server"
objExcel.Cells(1, 2).Value = "Site Code"
objExcel.Cells(1, 3).Value = UCase(strInbox) & " Count"
ListFolders(objGetPath)
Sub ListFolders(sPath)
Set oFolder = oFSO.GetFolder(sPath)
objExcel.Cells(intRow, 1).Value = UCase(strSiteServer)
objExcel.Cells(intRow, 2).Value = UCase(strSiteCode)
If objExcel.Cells(intRow, 3).Value = "" Then
objExcel.Cells(intRow, 3).Value = "None"
objExcel.Cells(intRow, 3).Value = oFolder.Files.Count
For Each oFldr In oFolder.SubFolders
ListFolders oFldr.Path
This SQL Query will allow you to retrieve Property information about your SQL server.
ServerProperty('ServerName') 'Server Name',
ServerProperty('ComputerNamePhysicalNetBIOS') 'Physical Machine',
'Instance Name' = Case
When ServerProperty('InstanceName') Is NULL Then ''
Else '<Unknown>'
End,
ServerProperty('Edition') 'Edition',
ServerProperty('ProductLevel') 'Product Level',
ServerProperty('ProductVersion') 'Product Version',
'Clustered' = Case
When ServerProperty('IsClustered') = 0 Then 'No'
When ServerProperty('IsClustered') = 1 Then 'Yes'
'Integrated Security' = Case
When ServerProperty('IsIntegratedSecurityOnly') = 0 Then 'No'
When ServerProperty('IsIntegratedSecurityOnly') = 1 Then 'Yes'
'Single User Mode' = Case
When ServerProperty('IsSingleUser') = 0 Then 'No'
When ServerProperty('IsSingleUser') = 1 Then 'Yes'
'Number Of Licenses' = Case
When ServerProperty('NumLicenses') Is NULL Then ''
ServerProperty('LicenseType') 'LicenseType'
If you receive an error similar to the one below when attempting to setup domain users home shares the issue is a permissions problem:
The home folder was not created because you do not have create access on the server. The user account has been updated with the new home folder value but you must create the directory manually after obtaining the required access rights.
To resolve the issue at the root share you must grant the Administrators or Domain Admins full control permissions to the root folder.
If you have the following directory folder: X:\Users you must grant the Domain Admins full control (NTFS) permissions to the folder (The folder is not shared). Then you can setup your user’s home shares without receiving the error above.