Add-in loading issue in citrix

Add-in Express™ Support Service
That's what is more important than anything else

Add-in loading issue in citrix
 
Amit B


Guest


All,

We are seeing a addin loading problem in citrix environment.
Please see the logs below. In first log file, the addin is loading fine when logged in as user A. In the second log file, the addin is not loading when logged in as User B. The installation on the citrix is done by an admin and our setup supports registered for all users.

I have few question -
1. In the second log file below, initial statement is 'The latest CLR version is 'v4.0.30319'. Then why adx is loading CLR is 2.0?

2. Through which registry entries the addin picks the .net versions?

3. Is the .net version controlled through citrix profiles or adx has a role to play?

4. What is the meaning of this statement 'The latest CLR version is 'v4.0.30319'. Does it mean that CLR 4.0 is required for addin to operate or does it mean that CLR 4.0 is detected?

5. Do you use any registry settings in user's local registry HKCU when addin is installed as RegiteredForAll users?
As per my understanding, if the installation is done for all users then only HKLM should be utilized. The reason why I am asking this is because we see different loading behavior on different profiles on same citix machine. May be the problem is with some corrupted registry.

6. Most important - Is there any tool to clean up all the adx registry entries completely? We want to clean up the session completely.

7. Is there any provision in addin to point to .net version or is this completely controlled through adx.

Best
AB


************************* Loading Fine (User A) *****************************************************
Add-in Express Loader Log File: 08/01/2017 13:28:45:555

Startup directory: C:\Program Files (x86)\**** Client\
Loader version: 8.2.4371.0
Operating System: Microsoft Windows Server 2008 R2 Standard Edition Service Pack 1 (build 7601), 64-bit
Process Owner: User
Command Line: "C:\Program Files (x86)\Microsoft Office\Office14\EXCEL.EXE" /automation -Embedding
Run 'As Administrator': No
Process Elevated: No
Integrity Level: Medium
UAC (User Account Control): Off
------------------------------------------------------------------------
13:28:45:560 1152 10268 Start.
13:28:45:560 1152 10268 Creating a new instance of the add-in loader.
13:28:45:560 1152 10268 Loading mscoree.dll
13:28:45:561 1152 10268 Success.
13:28:45:561 1152 10268 Loading the configuration from the system registry.
13:28:45:561 1152 10268 Getting the latest CLR version.
13:28:45:562 1152 10268 The latest CLR version is 'v4.0.30319'.
13:28:45:562 1152 10268 The configuration has been loaded successfully.
13:28:45:562 1152 10268 Runtime version: v4.0.30319.
13:28:45:562 1152 10268 Assembly name: ****, PublicKeyToken=36D6DE9C030E9182.
13:28:45:562 1152 10268 Class name: ****.AddinModule.
13:28:45:562 1152 10268 Registry key: CLSID\{F44EB779-26E0-4272-B0D3-001F6548BDB1}.
13:28:45:562 1152 10268 Attempting to create a new instance of the managed add-in class: CLR - v4.0.30319
13:28:45:562 1152 10268 Loading CLR: v4.0.30319.
13:28:45:562 1152 10268 Calling CLRCreateInstance method.
13:28:45:562 1152 10268 Success.
13:28:45:562 1152 10268 Calling GetRuntime method.
13:28:45:562 1152 10268 Success.
13:28:45:562 1152 10268 Checking if the hosting API of .NET Framework v4.0 beta is installed.
13:28:45:580 1152 10268 The hosting API is up to date.
13:28:45:580 1152 10268 Calling GetInterface method for the CorRuntimeHost interface.
13:28:45:580 1152 10268 Success.
13:28:45:580 1152 10268 Starting CLR...
13:28:45:580 1152 10268 Success.
13:28:45:580 1152 10268 Getting the CLR version.
13:28:45:580 1152 10268 The CLR v4.0.30319 has been initialized successfully.
13:28:45:580 1152 10268 Creating a new domain setup.
13:28:45:640 1152 10268 Success.
13:28:45:640 1152 10268 Getting the add-in directory.
13:28:45:640 1152 10268 Success. The directory is 'C:\Program Files (x86)\****\'
13:28:45:653 1152 10268 The configuration file is 'C:\Program Files (x86)\****\app.config'
13:28:45:653 1152 10268 The 'shadow copy' is enabled.
13:28:45:653 1152 10268 Creating a new application domain.
13:28:45:675 1152 10268 Success.
13:28:45:675 1152 10268 Creating an instance of the managed class. Assembly identity: '****, PublicKeyToken=36D6DE9C030E9182'
13:28:47:047 1152 10268 Success.
13:28:47:047 1152 10268 Unwrapping the managed class.
13:28:47:328 1152 10268 Success.
13:28:47:328 1152 10268 Querying the add-in extensibility.
13:28:47:328 1152 10268 Success.
13:28:47:328 1152 10268 Querying the custom task panes.
13:28:47:328 1152 10268 Success.
13:28:47:328 1152 10268 Querying the ribbon extensibility.
13:28:47:328 1152 10268 Success.
13:28:47:328 1152 10268 Querying the form regions.
13:28:47:328 1152 10268 Success.
13:28:47:329 1152 10268 Querying the encryption provider.
13:28:47:330 1152 10268 The 'EncryptionProvider' interface is not supported.
13:28:47:330 1152 10268 Getting the dispid of the 'Dispose' method.
13:28:47:334 1152 10268 Success.
13:28:47:334 1152 10268 The instance of the managed add-in class has been created successfully.
******************************************************************************************


************************* Not Loading (User B) *******************************************************

Add-in Express Loader Log File: 08/01/2017 13:11:38:248

Startup directory: C:\Program Files (x86)\**** Client\
Loader version: 8.2.4371.0
Operating System: Microsoft Windows Server 2008 R2 Standard Edition Service Pack 1 (build 7601), 64-bit
Process Owner: User
Command Line: "C:\Program Files (x86)\Microsoft Office\Office14\EXCEL.EXE" /automation -Embedding
Run 'As Administrator': No
Process Elevated: No
Integrity Level: Medium
UAC (User Account Control): Off
------------------------------------------------------------------------
13:11:38:248 2020 22136 Start.
13:11:38:248 2020 22136 Creating a new instance of the add-in loader.
13:11:38:248 2020 22136 Loading mscoree.dll
13:11:38:248 2020 22136 Success.
13:11:38:248 2020 22136 Loading the configuration from the system registry.
13:11:38:248 2020 22136 Getting the latest CLR version.
13:11:38:248 2020 22136 The latest CLR version is 'v4.0.30319'.
13:11:38:248 2020 22136 The configuration has been loaded successfully.
13:11:38:248 2020 22136 Runtime version: v2.0.50727.
13:11:38:248 2020 22136 Assembly name: ****, PublicKeyToken=36D6DE9C030E9182.
13:11:38:248 2020 22136 Class name: ****.AddinModule.
13:11:38:248 2020 22136 Registry key: CLSID\{F44EB779-26E0-4272-B0D3-001F6548BDB1}.
13:11:38:248 2020 22136 Attempting to create a new instance of the managed add-in class: CLR - v2.0.50727
13:11:38:248 2020 22136 Loading CLR: v2.0.50727.
13:11:38:248 2020 22136 Calling CLRCreateInstance method.
13:11:38:248 2020 22136 Success.
13:11:38:248 2020 22136 Calling GetRuntime method.
13:11:38:248 2020 22136 Success.
13:11:38:248 2020 22136 Checking if the hosting API of .NET Framework v4.0 beta is installed.
13:11:38:264 2020 22136 The hosting API is up to date.
13:11:38:264 2020 22136 Calling GetInterface method for the CorRuntimeHost interface.
13:11:38:264 2020 22136 Success.
13:11:38:264 2020 22136 Starting CLR...
13:11:38:264 2020 22136 Success.
13:11:38:264 2020 22136 Getting the CLR version.
13:11:38:264 2020 22136 The CLR v2.0.50727 has been initialized successfully.
13:11:38:264 2020 22136 Creating a new domain setup.
13:11:38:420 2020 22136 Success.
13:11:38:420 2020 22136 Getting the add-in directory.
13:11:38:420 2020 22136 Success. The directory is 'C:\Program Files (x86)\****\'
13:11:38:420 2020 22136 The configuration file is 'C:\Program Files (x86)\****\app.config'
13:11:38:420 2020 22136 The 'shadow copy' is enabled.
13:11:38:420 2020 22136 Creating a new application domain.
13:11:38:514 2020 22136 Success.
13:11:38:514 2020 22136 Creating an instance of the managed class. Assembly identity: '****, PublicKeyToken=36D6DE9C030E9182'
13:11:38:654 2020 22136 Could not load file or assembly '****, PublicKeyToken=36d6de9c030e9182' or one of its dependencies. This assembly is built by a runtime newer than the currently loaded runtime and cannot be loaded. Error code: 0x8013101b
Posted 01 Aug, 2017 14:52:38 Top
Andrei Smolin


Add-in Express team


Posts: 18826
Joined: 2006-05-11
Hello Amit,

#1. If your assembly is built using .NET 2.0 (3.0-3.5), this could explain why .NET 2.0 is loaded.
#2. System.Reflection.Assembly.LoadFrom(...).ImageRuntimeVersion
#3. See #2
#4. The loader detects that CLR 4.0 is the latest (newest) CLR version installed on that machine
#5. Add-in Express doesn't write to HKCU when registering a per-machine add-in. If you switched from per-user to per-machine installation recently, the keys created by the old version might influence the issue (but see below)
#6. Uninstall the add-in
#7. See #2

Amit B writes:
13:11:38:654 2020 22136 Could not load file or assembly '****, PublicKeyToken=36d6de9c030e9182' or one of its dependencies. This assembly is built by a runtime newer than the currently loaded runtime and cannot be loaded. Error code: 0x8013101b


This error occurs when the set of assemblies used to build the add-in assembly is different from the set of assemblies .NET find on the target machine. A simple example of this issue would show itself if you don't deploy a primary interop used by your add-in; in this case .NET finds and lets your assembly use the interop installed on the target machine - the error is raised if the interop version differs. Different versions of an assembly your add-in depends on, different cultures, etc. - these cause this error.


Andrei Smolin
Add-in Express Team Leader
Posted 02 Aug, 2017 02:59:14 Top