Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Resolving AddWpfBitmapMetadata call in MediaObjectMetadataExtractor
RyanONeill
#1 Posted : Friday, 6 May 2011 7:33:29 AM(UTC)
Rank: Member

Joined: 9/03/2010(UTC)
Posts: 4
Location: UK

Hi,

I found a couple of references to the following issue in the forums and have worked around it. My question is, why does it not work for me but obviously works for others?

The function AddWpfBitmapMetadata in TIS.GSP.Business.dll loads the assembly 'GalleryServerPro.Business.Wpf' but is unable to access the type information on line 884 which is;
Type metadataExtractor = assembly.GetType("GalleryServerPro.Business.Wpf.WpfMetadataExtractor");

Could it be because my ASP.Net hosting process is .Net 4.0 and this leads to differences in behaviour?

Link to the other forum post.

MSDN says the code provided should not work at all (as I read it);
Starting with the .NET Framework version 2.0, the runtime will not load an assembly that was compiled with a version of the .NET Framework that has a higher version number than the currently loaded runtime. This applies to the combination of the major and minor components of the version number.
From:
http://msdn.microsoft.com/en-us/library/25y1ya39.aspx


Or have I somehow downloaded the wrong source?

Thanks in advance

Ryan
Roger Martin
#2 Posted : Friday, 6 May 2011 11:40:41 AM(UTC)
Roger Martin

Rank: Administration

Joined: 3/08/2007(UTC)
Posts: 3,300
Location: Fort Atkinson, WI

The WPF project is compiled under .NET 3 but remember that .NET 3 and 3.5 really run in a .NET 2.0 process because they are simply extensions to .NET 2.0. So that's why it works.

In your case, I don't know why it doesn't work. Since you are running under .NET 4.0 anyway, I recommend you upgrade all the source code to that version. Then move the WPF code into the Business project and call its classes directly rather than through reflection. Finally, you can delete the WPF project.

I am actually going through that same process now, since GSP 2.5 will be .NET 4.0.
Roger Martin
Creator and Lead Developer of Gallery Server Pro
Rss Feed  Atom Feed
Users browsing this topic
Guest
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.