- Home /
Can't use Microsoft.Visualbasic?
Hello. I already tried placing the Microsoft.Visual basic.dll file in the assets folder of unity. My scripts are also placed in assets folder. No subfolders at all.
I'm using monodevelop. The reference folder in monodev shows a box with a little file beside the label Microsoft. Visualbasic.
tried changing the player settings in unity to. 2.0Net
tried using Microsoft. Office. Interop.excel, which shows the unexpected handler error, system.IO.filenotfoundexception. So Microsoft office can't work.
The monodevelop builds fine. But unity has an error: filenotfoundexception: could not load file or assembly 'system.deployment, version = 2.0.0.0, culture=neutral, publickeytoken=b03f5f7f1150a3a' or one of its dependencies.
I need to access Microsoft.visualbasic.finance.IRR function. Maybe there's another workaround.
Help!!!!!!!!
Answer by BusyRoots · May 27, 2020 at 08:34 AM
Hi there, just saw your question as I was searching an answer myself.
Fortunately I found one :).
Works for Unity Version 2019.3.0f3.
To use Microsoft.Visualbasic you need to add two DLL files to your Unity project.
Microsoft.Visualbasic.dll download dll
System.Deployment.dll download dll
Next you need to place them into your Assets in a folder called Plugins.
Last you need to tell Unity's compiler to take them into account (described here).
To do that you create a csc.rp file with the following content:
-r:Microsoft.VisualBasic.dll
-r:System.Deployment.dll
The csc.rp file needs to be in the Assets folder as well (for example Assets/AddCompiler)
Now everything should work just fine :).
Your answer
Follow this Question
Related Questions
Multiple Cars not working 1 Answer
Distribute terrain in zones 3 Answers
Making a bubble level (not a game but work tool) 1 Answer
An OS design issue: File types associated with their appropriate programs 1 Answer
Why can't I build Web Player in Unity while I have no problems with building standalone versions? 2 Answers