Recent versions of SAS Enterprise Guide (version 5.1 and later) use Microsoft .NET 4.0, which enforces additional security requirements before running custom task DLLs that you download from the Web, including those that you download from support.sas.com. Because these task DLLs are downloaded from the (big and scary) Internet, the Microsoft .NET runtime does not automatically "trust" them as it would trust a properly installed application. To enable the task to run, you must first "unblock" the file using Windows Explorer.
- Using Windows Explorer, browse to the assembly (DLL) that you downloaded from the samples and extracted from the Zip file.
- Right-click on the DLL file, and from the shortcut menu, select Properties.
The Properties dialog box opens.
- On the General tab, click Unblock to indicate that this DLL is trusted
(Note: the Unblock button will not appear if the assembly is already unblocked and available.)
- Click OK to close the Properties dialog box.
If the DLL is blocked when you try to add it in SAS Enterprise Guide, you might see a message such as the following, and the task will not appear in the Tools->Add-Ins menu:
Unable to load program .... Could not load file or assembly 'SAS.Tasks.Examples' or one of its dependencies Operation is not supported. (Exception form HRESULT: 0x80131515)
You can read more about this security feature and behavior in this Microsoft Knowledge Base article. If you build your own custom tasks (for example, by using the example projects and source code), you will not need to unblock the DLLs as you build them.
UPDATE from 03Jun2013: An alert reader (see the comments) found two additional useful hints:
- There is a Microsoft tool named streams.exe that you can use to automate this "unblock" operation for a set of files or entire folders.
- Even with these tools, you might require elevated privileges on your machine to modify a DLL file to "unblock" it. If all else fails, check with your local IT team to see if they can help with it.