Mogli
Mogli

Reputation: 2012

Unable to load .dll?

I made an application using c#.net 2.0 and linq but as we can't use Linq cause it was introduced in framework 3.5, i add some references of dll of version 3.5 and linq started working fine.

when i made the setup and installed it, it is working fine on my system but on other system it is showing error that

Unable to load System.Data.DatasetExtensions

I don't know that if other dlls are working then why this dll is creating problem? What is the solution for this?

Needs Help.Thanks.

Upvotes: 0

Views: 150

Answers (2)

spender
spender

Reputation: 120508

If you are constrained to using .Net2.0, then don't bother trying to load assemblies targeting later versions of .Net. It's doomed to failure. If you want to use Linq, target >=.Net3.5, if you need to target .Net2.0, don't use Linq.

Upvotes: 4

Ali
Ali

Reputation: 1409

Regarding error, the assemblies that you added may be having dependencies on other assemblies. It didn't give error on your system because you had it installed on it.

But you shouldn't be doing such a thing in general. A better way would be installing the required framework version within your installer as a pre-requisite requirement.

Upvotes: 1

Related Questions