See the top rated post in this thread. Click here

Results 1 to 5 of 5

Thread: Assembly won't load

  1. #1
    All AUGI, all the time
    Join Date
    2003-10
    Posts
    706
    Login to Give a bone
    0

    Default Assembly won't load

    I'm receiving this error (see below) in Civil 3D 2019 on one guy's computer here at the office so my custom DLL file won't load (I changed the name of the file to file.dll for AUGI purposes). It loads on everyone else's computer and loaded perfectly on his computer in Civil 3D 2017. This file has always been loaded directly from his C: drive and from the same place where it was located when it worked in 2017. Searches in AUGI came up with a solution to load it from a local drive but clearly that's not the problem. Any idea how to fix this? Other blogs talk about adding the switch to his ACAD.EXE.CONFIG file that would allow files to be loaded from a network but that doesn't seem to be the issue since we're loading it from his C: drive. Could installing 2019 and uninstalling 2017 have messed up his .NET framework or something? That's the only difference with his computer... we uninstalled 2017.

    Cannot load assembly. Error details: System.IO.FileLoadException: Could not load file or assembly 'file:///C:\file.dll' or one of its dependencies. Operation is not supported. (Exception from HRESULT: 0x80131515)
    File name: 'file:///C:\file.dll' ---> System.NotSupportedException: An attempt was made to load an assembly from a network location which would have caused the assembly to be sandboxed in previous versions of the .NET Framework. This release of the .NET Framework does not enable CAS policy by default, so this load may be dangerous. If this load is not intended to sandbox the assembly, please enable the loadFromRemoteSources switch.

  2. #2
    Member
    Join Date
    2009-04
    Posts
    13
    Login to Give a bone
    1

    Default Re: Assembly won't load

    How does that guy/computer obtain the DLL file (physically)? Do you send the DLL file out as email attachment/cloud drive (OneDrive, Google Drive, Dropbox...)? If so, when the file is downloaded to the computer, Windows would set a "unsafe" flag to the file, because it is from the Internet. This would cause the error when NETLOADing it into AutoCAD.

    If this is the case, the DLL file has to be unlocked by: right-click it in Window Explorer->Properties...->Security tab-> clear the "Locked" check box.

  3. #3
    Administrator BlackBox's Avatar
    Join Date
    2009-11
    Posts
    5,714
    Login to Give a bone
    0

    Default Re: Assembly won't load

    Quote Originally Posted by norman.yuan View Post
    ... the DLL file has to be unlocked by: right-click it in Window Explorer->Properties...->Security tab-> clear the "Locked" check box.
    1+

    I've just had to walk several folks through this in the past couple of weeks myself; for reference:

    https://forums.autodesk.com/t5/net/a...r/td-p/7905574


    Cheers
    "How we think determines what we do, and what we do determines what we get."

    Sincpac C3D ~ Autodesk Exchange Apps

    Computer Specs:
    Dell Precision 3660, Core i9-12900K 5.2GHz, 64GB DDR5 RAM, PCIe 4.0 M.2 SSD (RAID 0), 16GB NVIDIA RTX A4000

  4. #4
    All AUGI, all the time
    Join Date
    2003-10
    Posts
    706
    Login to Give a bone
    0

    Default Re: Assembly won't load

    Ha! That was it! Thank you!
    The weird thing is that when I want to give everyone an updated program I package up all of the updated files that support the DLL program as well as the DLL file into a ZIP file and simply tell people to UNZIP/Extract the files to the folder that they keep the program in, overwriting the old files. It's worked like that for years and has never "locked" the file. I have no idea why it locked it this time for this one guy.

    Thanks again

  5. #5
    Administrator BlackBox's Avatar
    Join Date
    2009-11
    Posts
    5,714
    Login to Give a bone
    0

    Default Re: Assembly won't load

    Why not just copy the finished update to the network and use NETLOGON (or a .BAT in Shell:Startup folder, if you don't have Domain Admin account) to replicate the network-saved copy to the user's workstation at login?

    Cheers
    "How we think determines what we do, and what we do determines what we get."

    Sincpac C3D ~ Autodesk Exchange Apps

    Computer Specs:
    Dell Precision 3660, Core i9-12900K 5.2GHz, 64GB DDR5 RAM, PCIe 4.0 M.2 SSD (RAID 0), 16GB NVIDIA RTX A4000

Similar Threads

  1. 2016: Assigning Assembly Description / Assembly Code to project elements
    By bombear1747061 in forum Revit MEP - General
    Replies: 0
    Last Post: 2017-07-03, 10:25 AM
  2. 2012: AutoCAD Error Unhandled exception...Could not load file or assembly
    By jodi_sherrell in forum AutoCAD General
    Replies: 2
    Last Post: 2013-05-03, 02:44 PM
  3. Replies: 15
    Last Post: 2012-07-20, 10:03 PM
  4. Replies: 1
    Last Post: 2012-05-28, 04:58 PM
  5. Replies: 1
    Last Post: 2012-05-28, 04:56 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •