Showing results for 
Search instead for 
Do you mean 
Community Home Request Access Read Blogs Share Your Ideas Search Community View My Settings
Reply
Tuned Listener
Posts: 4
Registered: ‎11-06-2009
Accepted Solution

.NET Extension Application not working with App Data Folder Redirection

SLX 7.5.2

 

We have a .NET application (.exe) that we are using in SLX.  SLX 'downloads' the .NET app to the user's App Data folder (in subdirectory). 

 

This works fine and dandy for all but those with App Data Folder Redirection. 

 

For those clients with App Data Folder Redirection, an error is thrown: "System.Security.SecurityException: That assembly does not allow partially trusted callers."  The application is considered an Intranet app because the redirection is a URL.

 

Has anyone ever encountered and solved this?  I saw a post from 2 years ago on another blog with no response.

 

Microsoft's solution (http://msdn.microsoft.com/en-us/library/9ykfdse9(v=VS.90).aspx) is quite involved and out of my realm of expertise.  I am praying there is another solution.

 

Please help!  I have 4 days to get this working….

Silver Super Contributor
Posts: 801
Registered: ‎03-24-2009

Re: .NET Extension Application not working with App Data Folder Redirection

In your .NET App - go to the solution properties. Select the Signing tab on left-hand side. Select Sign the Assembly. Choose a new strong key file name (.pfx). Change the password (and remember it). Ensure assembly has a new version (or update it) and Re-compile and check in the new assembly to Architect (and update releases). Should now work. I'll take the 3.75 days to my cash account in Switzerland - ker-ching !
Highlighted
Tuned Listener
Posts: 4
Registered: ‎11-06-2009

Re: .NET Extension Application not working with App Data Folder Redirection

Thanks Mike, but something's missing.  I'm still getting the error, but now I have a publicKeyToken.  Error messag attached.

 

I added

<Assembly: AllowPartiallyTrustedCallers()>

and that still didn't help.

 

A Microsoft article says something about Global Assembly Cache.  Do I need to addthe Assembly to it as they suggest?

 

Thanks in advance for your help!  I hate being so confused... I'm a .Net newbie, but an SLX oldie!  ;~)

Silver Super Contributor
Posts: 801
Registered: ‎03-24-2009

Re: .NET Extension Application not working with App Data Folder Redirection

Ah yes, now drag your dll to the \windows\assembly folder (physically drag it - don't cut/paste) - that should do it.
Tuned Listener
Posts: 4
Registered: ‎11-06-2009

Re: .NET Extension Application not working with App Data Folder Redirection

Thanks Mike, that worked!  But just for testing...

 

As a final solution, I had to create an installer and make sure the Global Assembly Cache Folder is included in the "File System on Target Machine".

 

Again, thanks, you help has been superb!