' By Jimmy Bergmark ' Copyright (C) 1997-2003 JTB World, All Rights Reserved ' Website: www.jtbworld.com / http://jtbworld.vze.com ' E-mail: info@jtbworld.com / jtbworld@hotmail.com ' This program is created for AutoCAD 2002 LT ' Removes the icon RedSpark in Open dialog box for the current profile ' If the profile is added to the command line as an argument it is used instead ' If the profilename includes spaces, use " around the name ' Example: remicons.vbs "<>" Sub main() On Error Resume Next Set WshShell = WScript.CreateObject("WScript.Shell") cv = WshShell.RegRead("HKLM\SOFTWARE\Autodesk\AutoCAD LT\R8\CurVer") if cv="" then WScript.Quit prof = "HKCU\SOFTWARE\Autodesk\AutoCAD LT\R8\" & cv & "\Profiles\" cp = WshShell.RegRead(prof) If WScript.Arguments.Count > 0 Then cp=strip(WScript.Arguments(0)) End If if cp="" then WScript.Quit key = prof & cp & "\Dialogs\AllAnavDialogs\DeletedExtensions\" WshShell.RegWrite key & "RedSpark", "", "REG_SZ" end sub function strip(arg) if left(arg,1)="""" and right (arg,1)="""" then strip=mid(arg,1,len(arg)-2) else strip=arg end if end function main