home *** CD-ROM | disk | FTP | other *** search
/ Chip 2004 October / Chip_2004-10_cd1.bin / chplus / guide / AppCompat-XPSP2.msi / _8A20A82799263F2E2F7D3C7DEA618834 / _A2592D9AFACD47F598C9BEEE031E75D0 < prev    next >
Encoding:
Text File  |  2004-08-23  |  2.1 KB  |  47 lines

  1. '=================================================================================
  2. 'This script is part of the appendix to the Application Compatibility Testing and 
  3. 'Mitigation Guide for Windows XP Service Pack 2. Before using these scripts you 
  4. 'must read the appendix and all Readme.txt files provided with the scripts. The 
  5. 'scripts are designed as functional samples and will require extensive testing and
  6. 'some modification for use in a production environment.
  7. '
  8. 'For information on additional functionality to incorporate into the script, such 
  9. 'as error checking, go to:
  10. '
  11. 'http://msdn.microsoft.com/library/default.asp?url=/nhp/default.asp?contentid=28001169
  12. '
  13. 'or
  14. '
  15. 'http://msdn.microsoft.com/library/default.asp?url=/library/en-us/rmscpt/html/rmscpt.asp
  16. '
  17. 'As some of the scripts edit the registry it is important that their functionality and 
  18. 'impact on the machine environment is thoroughly tested before they are used in a 
  19. 'production environment.
  20. '================================================================================== 
  21. ' Attachments.vbs
  22. '
  23. ' Author: Jim Captainino, Terry Tull (Content Master)
  24. ' Date:   08/20/04
  25. ' Revision History:
  26. '    Date    Comment
  27. '    08/20/04    Initial version started
  28.  
  29.  
  30. 'This script edits the registry to turn off attachment restrictions for Outlook Express.
  31. 'This script can also be used to turn on the feature.
  32. 'A value of 1 enables the feature
  33. 'A value of 0 disables the feature
  34.  
  35. 'Create a WshShell object
  36. Set WshShell = CreateObject("Wscript.Shell")
  37.  
  38. 'Read the default identity and save it to a variable, IDName. This value will vary between computers. 
  39. 'If multiple Outlook Express identities are used the correct identity must be specified instead of Default User ID.
  40. IDName = WshShell.RegRead("HKEY_CURRENT_USER\Identities\Default User ID")
  41.  
  42. 'Use the RegWrite method to write the appropriate value to the registry, specifying the value type.
  43. 'Use the IDName value to identify the correct identity.
  44. WshShell.RegWrite "HKEY_CURRENT_USER\Identities\" & IDName & "\Software\Microsoft\Outlook Express\" _
  45. & "5.0\Mail\Safe Attachments", "0", "REG_DWORD"
  46.