BizTalk Deployment: File is not a valid BizTalk Assembly - reference

I am using BizTalk 2020 and I have a project that I recently upgraded from BizTalk 2006. I have into the following error:
BTSTask.exe AddResource -Type:BizTalkAssembly -Source:"....\xxx.dll" -ApplicationName:"app1" -Options:GacOnAdd,GacOnImport,GacOnInstall
Microsoft (R) BizTalk Application Deployment Utility Version 3.13.717.0
Copyright (c) Microsoft Corporation. All rights reserved.
EXEC : error : File "....\xxx.dll" is not a valid BizTalk assembly. [F:\GIT\xxx\xxx.Deployment\Deployment.btdfproj]
Could not load file or assembly 'xxx.dll' or one of its dependencies. The system cannot find the path specified.
Command failed with 1 errors, 0 warnings.
What I have tried:
I check all the referenced assemblies and they are correct and in the GAC.
I have given access to the temp folder, for the account Network service.
in the deployment section of the project I have provided the target application name.
I have seen that the orchestration that is failing is of type System.Biztalk.BiztalkAssembly where the project that are of type System.Biztalk.Assembly deployed successfully. Could as yet not determine why there is a difference in the projects.
I am using Deployment framework 5.8 if that is of help.

Due to the error message...
"Could not load file or assembly 'xxx.dll' or one of its dependencies.
The system cannot find the path specified."
...you likely have an unwanted, incorrect version, incorrect .NET Framework version, or missing DLL referenced by your DLL.
I suggest downloading a free decompiler such as Telerik JustDecompile or JetBrains dotPeek, opening up your DLL in it, and carefully inspecting the references. The tool might even flag the problematic reference. Carefully check that the referenced DLL's exist on disk, that they are for the correct BizTalk version and matching .NET Framework version. There's a good chance that something was overlooked in the upgrade from BizTalk 2006.

Related

The type or namespace XXX could not be found(are you missing a using directive or an assembly reference?

I'm working on a project that targeting .NET 4.0 Framework. I added a reference to a third party dll file and call its methods in my code and have no error. But when I build the project it gave me The type or namespace error with blue underline on the methods of the dll. Using .NET Reflector I checked dll .NET Version of mscorlib.dll it is 4.0.0.0. My application Target .NET Version is 4.0 then Why I'm getting this error.
What I have done.
Remove all references to the library. Clean the project. Restart the project. again add the references. Not good in English please guide me. Stuck in it last 4 days.
Check if you have privileges to access the dll file. Then try running Visual Studio as administrator. If it does not help try to build the solution as 64x/86x not Any CPU.

Type or namespace name 'Diagnostics' does not exist in the namespace 'Microsoft.WindowsAzure'

I'm working with a pre-existing codebase from a software developer that has left my company. I've downloaded the source code from the repository. When I attempt to build the project, I get an error that says:
The type or namespace name 'Diagnostics' does not exist in the namespace 'Microsoft.WindowsAzure' (are you missing an assembly reference?)
I can't figure out how to get this project up-and-running. When I look at the NuGet packages associated with the project, I can see that the Windows Azure Configuration Manager and Windows Azure Storage packages are already installed. I'm not sure what I'm missing though.
Can someone tell me what I need to install on my machine to get past this error? Thanks!
I recently had this error. The problem was that the project was referencing Framework 3.5 and I have the 2.4 SDK installed which targets 4.0. Upgrade your project to target 4.0 and you should be fine.
I was getting this error on Visual Studio 2015 Update 3. This project's Azure Tools verion is 2.9.
I resolved this error by right clicking References under the project that has the error, then clicking Add Reference, then click Extensions under Assemblies. Find Microsoft.WindowsAzure.Diagnostics, check the box, and click OK. Now try rebuilding your project and hope for a different error.
The assembly should exist on your computer here: C:\Program Files\Microsoft SDKs\Azure.NET SDK\v2.9\bin\plugins\Diagnostics\Microsoft.WindowsAzure.Diagnostics.dll
If you do not see this assembly, it's most likely because you do not have the required Azure SDK. If you are using Azure SDK v2.9 like I am, you can download the SDKs here: Microsoft Azure SDK for .NET - 2.9
Then click download and select:
MicrosoftAzureLibsForNet-x64.msi (Microsoft Azure Client Libraries for .NET)
MicrosoftAzureTools.VS.140 (Microsoft Azure Tools for Microsoft Visual Studio 2015)
If you are using Azure SDK v2.7 then you will want to use this link: Microsoft Azure SDK for .NET - 2.7

Could not load file or assembly 'Microsoft.Xrm.Client

I have created a plug-in in CRM. It’s registered successfully. Inside my plug-in I have created a web service with many functions.
After successful calling of plug-in step I am getting error-
System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.Xrm.Client, Version=5.0.9689.2166, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies`. The system cannot find the file specified.
To solve this issue I have created the New XRM.cs file from crmsvcutil.exe but got the same issue. Searched more about this but no solutions found yet.
NOTE: I am using the Microsoft hosted version of CRM
Here below the reference files which I am using.
microsoft.crm.sdk.proxy
Microsoft.CSharp
microsoft.xrm.client
microsoft.xrm.portal
microsoft.xrm.sdk
System
System System.Core
System.Data
System.Data.Services
System.Data.Services.Client
System.DirectoryServices.AccountManagement
System.Runtime.Serialization
System.ServiceModel
System.Xml
System.Xml.Linq
Is there any way to run my plugin on Hosted version of CRM???
Appreciate if any help :)
I have solved this issue by using this command.
CrmSvcUtil.exe /out:"Xrm.cs"
/url:http://crm/Contoso/XRMServices/2011/Organization.svc
/namespace:Xrm
/servicecontextname:XrmServiceContext
/servicecontextprefix:Xrm
removing code customization options solved my issue.
/codeCustomization:"Microsoft.Xrm.Client.CodeGeneration.CodeCustomization, Microsoft.Xrm.Client.CodeGeneration"
Microsoft.XRM.Client is usually not needed by the plug-in.
It is needed to connect to CRM from an outside application.
Microsoft.XRM.Client has been removed from the SDK since CRM 2016.
Plugins do not automatically resolve dependencies in your project, they have to already be on the server.
Microsoft.XRM.Client can be placed in the GAC if it is needed by the plugin.
Update for Dynamics CRM 2015
The NuGet package Microsoft.CrmSdk.Extensions contains Microsoft.Xrm.Client.
Update for Dynamics CRM 2016 and Dynamics 365
Microsoft.Xrm.Client is no longer part of the SDK.
The NuGet package Microsoft.CrmSdk.CoreAssemblies contains everything needed for plugin development.
The various parts of the Dynamics CRM SDK are in NuGet.
NuGet is a much better solution than adding Dynamics CRM dlls as project references; especially for source control and team development.
Microsoft.Xrm.Client.dll doesn't actually appear to work if running from the GAC. This is because of some dodgy type resolution methods it has that only work if the assembly is loaded locally. I have raised an issue with full details about that here: https://community.dynamics.com/crm/f/117/t/144464.aspx

Issue with ReportViewer on Windows Azure websites (WAWS)

In one of my project i have used reportviewer control to display reports on web pages and at time of uploading on Azure I have followed the steps mentioned here
After uploading when i runs that report web page then it's giving me below error
An error occurred during local report processing.
The definition of the report 'Reports\Report1.rdlc' is invalid.
An unexpected error occurred in Report Processing.
Could not load file or assembly 'Microsoft.ReportViewer.ProcessingObjectModel, >
Version=10.0.0.0,
Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its
dependencies. The system cannot find the file specified.
What should be cause of this?
Update:
I have added following 2 dlls as shown in below snap
Microsoft.ReportViewer.Common.dll (10.0)
Microsoft.ReportViewer.WebForms.dll (10.0)
After long research i found solution of my problem from this link
The problem with missing reference of below dlls
Microsoft.ReportViewer.ProcessingObjectModel.dll
Microsoft.RevportViewer.DataVisualization.dll
but after instaling i could not found those dlls in C:\Windows\Microsoft.NET\assembly\GAC_MSIL
But there is assembly files available in this path C:\Windows\assembly
then i have added those dlls using VS2010 directly as shown in below fig.
And it's worked!
What is the version of ReportViewer you have used in this project and would you please specify how many and which one Reference DLL you have included in your project? This will help to ensure that you have included all the DLL properly in your project. You must use Report Viewer SP1 which is compatible with Azure DB, and the same SP1 language pack.
I would suggest FTP to your website and verify that you do have all the DLL uploaded correctly as you configure in your project. This is the best way to check in Windows Azure Websites if all the configured files made it to file server.

What makes deployment successful for some users and unsuccessful for others?

I am trying to deploy a Visual C++ application (developed with Microsoft Visual Studio 2008) using a Setup and Deployment Project. After installation, users on some target computers get the following error message after launching the application executable: “This application has failed to start because the application configuration is incorrect. Reinstalling the application may fix the problem.” Another user after installation could run the application properly. I cannot find the root cause of this problem, despite spending several hours on the Visual Studio help files and online forums (most postings date back to 2006). Does anyone at Stack Overflow have a suggestion? Thanks in advance. Additional details appear below.
The application uses FLTK 1.1.9 for a GUI library, as well as some Boost 1.39 libraries (regex, lexical_cast, date_time, math).
I made sure I am trying to deploy the release version (not the debug version) of the application. The Runtime library in the Code Generation settings is Multi-threaded DLL (/MD).
The dependency walker of myapp.exe lists the following DLLs: wsock32.dll, comctl32.dll, kernel32.dll, user32.dll, gdi32.dll, shell32.dll, ole32.dll, mvcp90.dll, msvcr90.dll.
In the Setup and Deployment Project, I add the following DLLs to the File System on Target Machine: fltkdlld.dll, and a folder named Microsoft.VC90.CRT with msvcm90.dll, msvcp90.dll, mcvcr90.dll and Microsoft.VC90.CRT.manifest.
The installation process on the target computers getting the error message requires having the .Net Framework 3.5 installed first.
Any suggestion? Thanks in advance!
Add the Visual C++ Redistributable to your Deployment project and be sure to run Setup.exe instead of the MSI when installing. This will invoke the VCRedist bootstrapper to ensure your PC has those pieces before installing your app.
Dependency Walker only shows static (link time) dependencies - it cannot possibly know about dynamic dependencies such as COM objects.
I had a similar problem after the ATL security updates last year. My app needed a later version of the C++ runtime libraries than the deployment project included.
Try running Windows Update on the target machines after installation, or download and install the latest (28 July 2009) C++ redistributable package directly.
http://support.microsoft.com/?kbid=973551
That solved the problem for me. I haven't fixed the deployment project yet though.

Resources