Questions tagged [assemblies]
Assemblies are collections of compiled .Net types and resources grouped into a logical and physical unit (in the form of a .dll file or .exe file).
2,371
questions
1
vote
0
answers
16
views
Weird dependency on system.web.mvc v3, when everything has an explicit reference to v5.2.3
I'm trying to track down a build problem in VS 2013 and an ASP.NET MVC project.
The build fails, but the only meaning full looking message is an assembly conflict warning.
I fixed it enough for the ...
1
vote
1
answer
41
views
CLR Reflection and Metadata management - where is the truth?
I always thought that Reflection in CLR loads metadata for types on demand, when you actually request needed information. And then it is cached, and all subsequent calls will be cheaper. At least, ...
0
votes
1
answer
92
views
.NET 6 Library referenced in MAUI project fails to compile in Release configuration with AOT error
I have a MAUI project which references a .NET 6 Class Library (itself including an EF Core context with related NuGet packages and all the model objects). This class is referenced as a .NET Assembly ...
0
votes
1
answer
17
views
Unity "Predefined type 'System.ValueTuple`3' is declared in multiple referenced assemblies". VERSION: 2020.3.17f1
One day I open my project and now have 50 errors from unity built in packages saying that System.ValueTuple is defined in multiple places. Visual Studio is finding any problems, and my many google ...
0
votes
1
answer
79
views
Problem downloading Firebase packages to Unity project
I am receiving the error: dusplicate precompiled assemblies with the same name are now allowed -
assets/mobiledependencyresolver/editor/google.version.dll
assets/externaldependencyresolver/editor/...
0
votes
0
answers
49
views
Need to migragte assemblies from SQL Server 2016 to SQL Server-2019 with TDE
A former colleague created some assemblies in SQL Server 2008 and we could migrate them easily to SQLServer 2016. I was able to do this myself so far but with SQL_Server 2019 policies have changed and ...
1
vote
0
answers
104
views
New-Object cmdlet error indicates assemblies not loaded
I am trying to extract a dacpac from a SQL Server database via Powershell script. Using this MS example found here Extract a DAC using PowerShell
The code is as follows:
Import-Module SqlServer
## ...
0
votes
1
answer
99
views
Is it possible to develop a .NET library with optional reference/dependency and still benefit from IntelliSense/typing?
Let's say I want to write a library and it should invoke OptionalLibClass.Run() if such method is available. However the assembly is big (like SkiaSharp) so I do not want to include it with my library,...
0
votes
0
answers
105
views
Add Assembly from SQL Server Database Project with Other DLL dependencies
I am currently having an issue deploying some assemblies to using Visual Studio 2022. One Assembly is dependent of MySQl.data.dll and I get the error message below
Error: SQL72014: .Net SqlClient ...
0
votes
0
answers
14
views
All compiler has assembler?
Are all programming languages compiled into assembly language? And then assembly translate them to machine code? And all of structured language has a compiler involved assembler?
This is computer ...
2
votes
0
answers
14
views
protected internal method telling can not change access modifiers when overriding in a different assembly [duplicate]
I have two projects in one solution and I added a dependency of assembly A in the assembly B
So here I have the asembly A where I have the folloing class
public class Person {
protected virtual ...
0
votes
1
answer
41
views
Run application in context of multiple directories in order to use a base set of assemblies and an external set of assemblies
The problem and current solution
A business app needs to interface with a 3rd party app which provides external client data. The 3rd party API is through client-specific assemblies which are provided ...
0
votes
0
answers
31
views
What are the default assemblies loaded in dotnet (5 in particular)
I am struggling to understand which assemblies are loaded by default and adding a using statement to its namespace is enough to use it, vs when the actual assembly is not being loaded.
Here is an ...
1
vote
1
answer
317
views
How to exclude UnityEditor reference from asmdef?
How to exclude UnityEditor reference from asmdef?
Why I need it:
I have an asmdef file. For example, it is MyAssembly/MyAssembly.asmdef. The MyAssembly contains a lot of features and each feature ...
-1
votes
1
answer
46
views
The type for namespace name 'FormHome' could be not be found {are you missing a using directive or an assembly reference}
there is no place for assemlbies in my project. I tried many methods to find it, but without success.
0
votes
0
answers
183
views
Failure to restore System.DirectoryServices assembly in .Net Core
I am using .Net core 3.1.
While I am trying to restore packages the Nuget packages are getting restored but the two assemblies 'System.DirectoryServices' and System.DirectoryServices.AccountManagement ...
0
votes
2
answers
729
views
Compress Xamarin Android APK assemblies
Is it possible to compress Xamarin assemblies into assemblies.blob after decompressing them using decompress-assemblies command line tool included in xamarin-android?
0
votes
1
answer
203
views
Runtime error with a very basic reflection example in C#
I'm trying to learn a bit more about System.Reflection using the official microsoft docs. Specifically I'm trying to run the following example:
// Loads an assembly using its file name.
Assembly a = ...
2
votes
1
answer
412
views
How to sign a SQL Server assembly created with assembly_bits / hex bytes?
I'm working on an upgrade to SQL Server 2019 and I need to sign assemblies. However, the assembly code I have is using assembly_bits / hex bytes. I cannot find a good way to sign this assembly. How ...
3
votes
0
answers
108
views
How to measure .NET assembly load time
I want to measure the time that .NET runtime takes to load individual assemblies.
To start, I've prepared the following console app:
public static void Main(string[] args)
{
var timer = Stopwatch....
1
vote
1
answer
201
views
Trustworthy is ON with UNSAFE assemblies not running
I am just testing something internal and now the TRUSTWORTHY is set to ON security risks.
I am wondering though, if TRUSTWORTHY is ON, can an UNSAFE assembly stop working if it is signed and and has ...
1
vote
1
answer
627
views
A SQL CLR Assembly set to UNSAFE with a key is no longer working
I have had an UNSAFE assembly running on an internal only database and web application but the IT dept. might have changed something as we noticed it just stopped working and trying to figure out why.
...
0
votes
1
answer
166
views
What does it mean by "recompile assemblies" in the following?| C#
I faced the follwing section when reading a book about C#:
Constants should be avoided for two important reasons: the value must
be known at compile time, and it must be expressible as a literal
...
2
votes
0
answers
516
views
Assembly resolution fails for dlls in work directory after upgrading to .NET 6
I am upgrading a program from .NET Framework to .NET 6 and have stumbled upon an issue with assembly loading.
The program is plugin-based with plugin dlls residing in a subfolder of the main folder (...
1
vote
0
answers
152
views
Packaged Xamarin Forms UWP app crashes on launch - works in VS Debug and Release modes
I've been re-writing an app and run into (again :-( ) that it's working in both Debug and Release modes, but the packaged app crashes on launch. i.e. never even gets to the app's home screen. I had ...
0
votes
1
answer
1k
views
.Net core 6: How to have output directory without assemblies
I am porting company products in .Net core 6 from .Net 4.8.
In the solution, there is an output directory containing:
Assemblies, Configuration, Log, Resources directories and only .exe, .pdb and .exe....
0
votes
1
answer
47
views
Different NuGet package in separate solutions
I have two solutions Sln1 and Sln2, Sln1 have two projects (there are more but, this situation is used for simplicity) projectA and ProjectB. ProjectA is WebApi and ProjectB is Class library project. ...
0
votes
0
answers
253
views
Two simple questions about application manifest and assembly of Visual Studio project
I created a simple Win Form project, MyApp, with Visual Studio 2013 & C# .NET.
In order for the app to target Windows 10 and Windows Server 2019, I included an app (executable) manifest for the ...
1
vote
1
answer
259
views
Why are methods missing from this object?
Having a really strange issue I haven't seen before. I am following a tutorial on how to use Selenium and ChromeDriver to script browsing. After loading WebDriver.dll and chromedriver.exe into my ...
0
votes
1
answer
1k
views
Could not load file or assembly 'System.Data.SQLite, Version=1.0.115.5
.NET Framework project - added SQLite to my project via Nuget package, app.config and package.config look correct.
Errors is:-
"Type : System.IO.FileNotFoundException, mscorlib, Version=4.0.0.0, ...
0
votes
0
answers
126
views
Best way to manage assembly reference in a .Net project
I have a solution which contains 108 projects. There are few projects which are referred in other projects.
I am simplifying the solution and taking projects out of the solution and managing the ...
0
votes
0
answers
226
views
Load assembly in DefaultDomain of IIS
Good morning,
I am working on a simple ASP.net application. I have implemented some code which is in C# dlls. Those dlls are used and loaded by the ASP.net application. The goal is to put the C# dlls ...
0
votes
0
answers
449
views
Publish SQLCLR program fails because is not trusted even though it IS in sys.trusted_assemblies
I am trying to use SQLCLR to get a list of files on another server. I have created an SQL Server Database Project to do this.
Next, I have tried to whitelist my assembly using the method given here: ...
1
vote
1
answer
277
views
could not load file or assembly the located assembly's manifest definition does not match the assembly reference
I updated our WebView2 version to the latest but I have one project still complaining about missing the old version assembly. My solution builds fine, but complains when I attempt to debug it.
I've ...
0
votes
1
answer
146
views
Visual Studio Code cannot import assemblies containing Hyper-V data types to build PowerShell objects
Problem Description and Background
I am building some custom PowerShell objects that require the Hyper-V data types. I found the Hyper-V data types by using commands
[System.AppDomain]::...
2
votes
1
answer
702
views
System.MissingMethodException - Microsoft.Data.SqlClient
I'm developing plugin based application using MEF2 - System.Composition.
My shell is targeting .NET Core 5.0 (assembly name: PI.exe).
My Infrastructure library contains interfaces, class and ...
0
votes
1
answer
4k
views
Unity Multiple Assembly Definition Files Error
I am a beginner in Unity and when I was working on a project I had the error Folder 'Assets/JMO Assets/Toony Colors Pro/Demo TCP2/Common Demo Assets/Kino Bloom/Editor/' contains multiple assembly ...
-1
votes
1
answer
258
views
Matlab: Could not load file or assembly
Fair warning, I'm relatively new to using Matlab and Visual Studio.
I've been trying to create code that I can use to communicate through a USB to an arduino. I found some example code using a library ...
2
votes
0
answers
212
views
How the CoreCLR resolves project dependencies?
Lately, I was working on a tool that verifies if a given binary could load the needed dependencies at runtime, for .NET Framework binaries the resolution of dependencies is pretty straightforward as ...
1
vote
0
answers
564
views
Avoid dependentAssembly within app.config (.net framework)
I'm looking for a way to avoid the need to add dependentAssembly within the app.config file.
The actual related project is a library that should be added to a global process. It's not possible to ...
1
vote
2
answers
945
views
Why am I Able to load x64 assembly into AnyCPU Prefer 32 bit executable?
I am working on a tool that loads different assemblies using System.Reflection's method Assembly.Load
Here is what i get
On a 64bit OS, if application configured with :
x64 loads x64 & AnyCPU ...
0
votes
0
answers
833
views
How Can I Get Target Framework Of An Assembly?
I am loading different assemblies using Mono.Cecil and I would like to know if the assembly is targeting .NET Framework or .NET Core.
What I have tried is retrieving the custom attribute ...
0
votes
1
answer
123
views
How can i mock a return type of a factory method of a 3rd party library?
I am working on a tool that loads assemblies using Mono.Cecil. I have the following Factory that returns an object named binary and depends on interface responsible for loading assemblies with ...
0
votes
0
answers
112
views
Assembly '' references assembly 'microsoft.sqlserver.dtsruntimewrap, ', which is not present in the current database
I created an assembly of microsoft.sqlserver.dtsruntimewrap as my code got this dependency.
It created the assembly succesfully.
So when I created an assembly of my script as follow :
CREATE ASSEMBLY ...
0
votes
1
answer
427
views
Why are DLL and EXE files in an .NET context called assemblies? [duplicate]
A colleague complained that the "assembly" I gave him (a regular, non-NET compiled C++ DLL-file) didn't work. I replied "What's... an assembly?".
So by reading this dot net ...
0
votes
0
answers
101
views
How to protect unity assembly without compiling to IL2CPP? [duplicate]
For a long time we deploy our games in IL2CPP mode to protect unity assemblies, and now I'am looking for techs to make the DLLs unreadable by ilspy, dnSpy and the like, while the DLLs can be read ...
0
votes
1
answer
217
views
C# how to use read method in assembly type [closed]
I am writing a Data Acquisition app that uses a wrapper class around HW drivers. My goal is for external users should be able to write their own wrappers for their hardware. It seems assemblies is the ...
1
vote
1
answer
392
views
How to let my code access assembly while impersonating
I'm trying to read images on a shared folder using WindowsIdentity.RunImpersonated. The problem is that during impersonation, my code can't access the System.Drawing.Common assembly, probably because ...
0
votes
1
answer
176
views
Is `GetReferencedAssemblies` a subset of `AppDomain.CurrentDomain.GetAssemblies()`?
I want to test some reflection code I've written.
There's an edge case that would occur if the ReferencedAssemblies were ever not already loaded into the AppDomain, i.e. if the following expression ...
1
vote
1
answer
3k
views
Where is System.Windows.Forms assembly
I have Visual Studio 2019, and an empty .net framework project.
I would like to build a windows forms project by code only (without using
any template).
For this goal I need System.Windows.Forms ...