Question : What is the best possible way to rename computer names?  I have 200 clients?

Perhaps a VB tool that will prompt me for the old computer name then the new one. Search the network and change the compute name.  Any ideas or methods?

Answer : What is the best possible way to rename computer names?  I have 200 clients?

OK, lets try this:

--------------------------------------------------------------------------------------------------------

Dim objExcel, strPathExcel, objFile

Set objExcel = CreateObject("Excel.Application")
strPathExcel = "\\DS\ADLookup\ADLookupR.xls"
objExcel.Workbooks.open strPathExcel
Set objSheet = objExcel.ActiveWorkbook.Worksheets(1)
Set SH = CreateObject("WScript.Shell")

row = 1

newName = ""

Do While Trim(objSheet.cells(row, 1).Value) <> ""
   CName = objSheet.cells(row, 1)
   objSheet.cells(row, 6) = "CHANGED"
   objSheet.cells(row, 7) = Trim(CStr(Now))
   newName = Trim(objSheet.cells(row, 5).Value)
   
   SH.Run "RENCOMP " + CName + " " + newName, 0, true

   a = MsgBox("Changed " + CName + " to " + newName + "!", vbInformation)
 
   row = row + 1
Loop

objExcel.ActiveWorkbook.Save
objExcel.ActiveWorkbook.Close
Random Solutions  
 
programming4us programming4us