Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
This question was closed Jan 27, 2015 at 08:41 PM by kiriri for the following reason:

The question is answered, right answer was accepted

avatar image
0
Question by kiriri · Aug 29, 2014 at 02:44 PM · windowssystemexceptiondependency

unity could not load from assembly [resolved]

Hi,for one of my projects I need to reference System.Drawing.dll in Windows, so I copied it into the Asset folder. Now I keep on getting the following Exception when I compile and run the game.

TypeLoadException: Could not load type 'System.IO.InternalBufferOverflowException' from assembly 'System.Drawing'

What could it be I'm doing wrong?

Comment
Add comment · Show 7
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image gjf · Aug 29, 2014 at 02:50 PM 0
Share

does it show up in unity?

avatar image kiriri · Aug 29, 2014 at 03:00 PM 0
Share

@gjf the exception only shows in the development console, the editor uses the dll just fine.

avatar image gjf · Aug 29, 2014 at 03:13 PM 1
Share

this executes (admittedly it doesn't really do anything):

 using UnityEngine;
 
 public class DrawTest : $$anonymous$$onoBehaviour
 {
     public void Start ()
     {
         var newImage = new System.Drawing.Bitmap(64, 64);
     }
 }

i needed to copy the dll into the same folder as the script, but no errors.

EDIT: you did copy the mono version and not the windows one, right?

avatar image gjf · Aug 29, 2014 at 03:20 PM 1
Share

mono's .net is the one unity uses so you're likely to get all sorts of unpredictable behaviour using the dll's from windows. sadly, the mono version is rather dated right now, but the drawing stuff that i've used works well enough.

avatar image kiriri · Aug 29, 2014 at 03:28 PM 1
Share

@gjf You were right, with mono I'm not getting any errors at all. Unfortunately I'd really need them because now it's doing absolutely nothing :D But that is another issue entirely. Thank you for helping me, I really appreciate the guidance !

Show more comments

0 Replies

  • Sort: 

Follow this Question

Answers Answers and Comments

22 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Error initializing license system (Windows 8.1) 0 Answers

How to set WindowStyle (hide MINIMIZE and MAXIMIZE buttons) 0 Answers

Accessing local system ( File Browser ) 2 Answers

Creating a Directory in "My Documents" 2 Answers

IOException build error 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges