NextPVR Forums
  • ______
  • Home
  • New Posts
  • Wiki
  • Members
  • Help
  • Search
  • Register
  • Login
  • Home
  • Wiki
  • Members
  • Help
  • Search
NextPVR Forums Public Developers v
« Previous 1 … 12 13 14 15 16 … 93 Next »
Resolving required plugin assemblies problem

 
  • 0 Vote(s) - 0 Average
Resolving required plugin assemblies problem
imilne
Offline

Posting Freak

Posts: 2,423
Threads: 135
Joined: Feb 2008
#21
2011-04-01, 03:49 PM
sub Wrote:Did you try LoadLibrary before calling any methods that depend ond the DLL?

I haven't had a chance to get back to it. I did come across the following, but I'm not sure if I can get my head around it:

http://blogs.msdn.com/b/jonathanswift/ar...2900_.aspx

I got sidetracked pulling info out of MediaInfo itself, then investigating how to do OSD popups. Need to stop trying to do too many things at once and just concentrate on getting one thing working Big Grin
sub
Offline

Administrator

NextPVR HQ, New Zealand
Posts: 106,788
Threads: 769
Joined: Nov 2003
#22
2011-04-01, 04:01 PM
imilne Wrote:I haven't had a chance to get back to it. I did come across the following, but I'm not sure if I can get my head around it:

http://blogs.msdn.com/b/jonathanswift/ar...2900_.aspx
Basically, your code would be unchanged except for adding following interop definition in your plugin:

[DllImport("kernel32.dll")]
public static extern IntPtr LoadLibrary(string dllToLoad);


Then in the plugin's constructor, call LoadLibrary("c:\path\to\mediainfo.dll"). Everything else should be unchanged, but it should then be able to find mediainfo.dll when it needs it.
imilne
Offline

Posting Freak

Posts: 2,423
Threads: 135
Joined: Feb 2008
#23
2011-04-01, 05:47 PM
sub Wrote:Basically, your code would be unchanged except for adding following interop definition in your plugin

Yep, that's all it needed, thanks! That's one less thing to worry about Smile

Iain
sub
Offline

Administrator

NextPVR HQ, New Zealand
Posts: 106,788
Threads: 769
Joined: Nov 2003
#24
2011-04-01, 05:58 PM
great
mvallevand
Offline

Posting Freak

Ontario Canada
Posts: 53,096
Threads: 957
Joined: May 2006
#25
2011-04-03, 01:17 AM
Can something like this be used by a console app to find NUtility and Nshared?

Martin
sub
Offline

Administrator

NextPVR HQ, New Zealand
Posts: 106,788
Threads: 769
Joined: Nov 2003
#26
2011-04-03, 01:25 AM
That method will only really help with native code.

Also, if you do have a project that depends on NUtility.dll or NShared.dll, be aware that some of the interfaces from these DLLs only have an implementation in NextPVR.exe, so these things wont function when you use them in some other executable.
McBainUK
Offline

Posting Freak

Posts: 4,711
Threads: 429
Joined: Sep 2005
#27
2011-04-03, 03:07 PM
McBainUK Wrote:My plugin is split up in to a number of dlls. Unless all the files are in the Plugins\Common folder I get this error
Any more ideas re this problem?
Wiki profile
My Projects
Programs Plugin [SIZE=2](retired)
| Volume OSD Plugin (retired) | Documentation Wiki (retired)
[/SIZE]
sub
Offline

Administrator

NextPVR HQ, New Zealand
Posts: 106,788
Threads: 769
Joined: Nov 2003
#28
2011-04-03, 04:20 PM
Can you try again with this patch, then post the logs? It logs info about the stack etc, as it tries to match a plugin.
McBainUK
Offline

Posting Freak

Posts: 4,711
Threads: 429
Joined: Sep 2005
#29
2011-04-04, 07:44 AM
sub Wrote:Can you try again with this patch, then post the logs?
Here you go.
Wiki profile
My Projects
Programs Plugin [SIZE=2](retired)
| Volume OSD Plugin (retired) | Documentation Wiki (retired)
[/SIZE]
sub
Offline

Administrator

NextPVR HQ, New Zealand
Posts: 106,788
Threads: 769
Joined: Nov 2003
#30
2011-04-04, 05:51 PM
When .net fires an event to say it cant resolve an assembly, it doesnt give me any information about what was trying to load the assembly in the first place, so the app has to try to work it out, otherwise it can only load the assembly from the main application directory. To try working it out, it looks through the current stack to see if it can find a match from the assembly with a loaded plugin. Unfortunately in this case, MusicSpot doesnt appear to be executing anywhere in the current stack, so the app is unable to work it out.
« Next Oldest | Next Newest »

Users browsing this thread: 1 Guest(s)

Pages (4): « Previous 1 2 3 4 Next »


Possibly Related Threads…
Thread Author Replies Views Last Post
  PIP plugin for Kodi sgilani 2 3,018 2022-10-17, 12:44 AM
Last Post: sgilani
  New Systems Plugin kirschey 10 3,504 2020-11-14, 08:01 PM
Last Post: sub
  NextPVR 5: When is PIN Required for API Access? pkscout 3 2,799 2020-05-26, 04:45 AM
Last Post: sub
  VIdeo playback from plugin mvallevand 5 3,592 2015-08-06, 10:43 PM
Last Post: sub
  Attention Sub: Open TV / Custom Data Grabber plugin Benoire 2 2,981 2014-11-14, 02:05 AM
Last Post: Benoire
  Trouble loading .NET System assemblies bgowland 3 2,442 2013-10-31, 02:37 AM
Last Post: bgowland
  API docs to help with plugin development? McBainUK 3 2,841 2013-06-08, 06:14 PM
Last Post: sub
  Refreshing TV Guide Data (after System plugin EPG update) imilne 13 6,279 2013-03-24, 08:03 PM
Last Post: imilne
  sabnzbd plugin to show processed files Wakalaka 1 2,005 2013-03-12, 06:48 AM
Last Post: psycik
  Problem with preview image for Pending Recordings Northpole 2 2,048 2012-08-14, 02:56 AM
Last Post: Northpole

  • View a Printable Version
  • Subscribe to this thread
Forum Jump:

© Designed by D&D, modified by NextPVR - Powered by MyBB

Linear Mode
Threaded Mode