MediaPortal Forums HTPC/MediaCenter

Go Back   MediaPortal Forum » Language specific support » Deutsches MediaPortal Forum » Media Portal - Support » Plugins/Erweiterungen


Plugins/Erweiterungen Alles um Erweiterungen des MediaPortal welche NICHT in Release oder SVN-Versionen enthalten sind!

Reply
 
Thread Tools Display Modes
Old 2005-07-04, 20:29   #1 (permalink)
Portal User
 
Join Date: Feb 2005
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts


Default Probleme mit dem Tutorial "How to write a plugin for Media Portal"

Hallo,

ich bin Java-Entwickler und mache gerade meine erste Geh-Versuche mit .NET und orientiere mich an dem Tutorial "How to write a plugin for Media Portal" (http://mediaportal.sourceforge.net/P...inTutorial.htm).

Nachdem ich endlich alles installiert und mein erstes .NET-Programm kompiliert habe (und das hat gedauert - MS sei dank *Grins*) habe ich ein paar Schwierigkeiten bei dem "OurPlugin"-Bsp. Zuerst sind mir da ein paar Tippfehler im SourceCode aufgefallen: z.B. "using Media Portal.GUI.Library;" statt "using MediaPortal.GUI.Library;" (Leerzeichen)

Im Prinzip läuft das Plugin nun - nur der Dialog erscheint noch nicht wenn ich Button1 oder 2 auswähle. Folgender Fehler war im Log zufinden (Ach so, mein Plugin heißt MatthiasPlugin anstelle von OurPlugin):

04.07.2005 20:08:08 GUIWindow:OnWindowLoaded id:1 exer Objekttyp kann nicht zum Zieltyp konvertiert werden. at System.Reflection.RuntimeFieldInfo.InternalSetValu e(Object obj, Object val, BindingFlags invokeAttr, Binder binder, CultureInfo culture, Boolean requiresAccessCheck, Boolean isBinderDefault)
at System.Reflection.RuntimeFieldInfo.SetValue(Object obj, Object val, BindingFlags invokeAttr, Binder binder, CultureInfo culture)
at MediaPortal.GUI.Library.GUIWindow.OnWindowLoaded()
04.07.2005 20:08:09 OnMessage exceptionystem.InvalidCastException: Die angegebene Umwandlung ist ungültig.
at MatthiasPlugin.Class1.OnButtonTwo()
at MatthiasPlugin.Class1.OnClicked(Int32 controlId, GUIControl control, ActionType actionType)
at MediaPortal.GUI.Library.GUIWindow.OnMessage(GUIMes sage message)
04.07.2005 20:08:12 OnMessage exceptionystem.InvalidCastException: Die angegebene Umwandlung ist ungültig.
at MatthiasPlugin.Class1.OnButtonOne()
at MatthiasPlugin.Class1.OnClicked(Int32 controlId, GUIControl control, ActionType actionType)
at MediaPortal.GUI.Library.GUIWindow.OnMessage(GUIMes sage message)

Liegt das eventuell an einer "kaputten" CVS-Version die ich gezogen habe, oder mache ich einfach was anderes falsch?

Ich würd mich über Hilfe freuen!

Vielen Dank!
Xanthophix is offline   Reply With Quote
Old 2005-07-12, 22:08   #2 (permalink)
Portal User
 
Join Date: Feb 2005
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts


Default Re: Probleme mit dem Tutorial "How to write a plugin for Media Portal"

Hallo, ich hab das Problem mittlerweile lösen können.

Es lag tatsächlich an der CVS-Version die ich gezogen habe. Setzt man die Verweise zur core.dll und dialog.dll auf Dateien aus dem MP-Release 1.2 funktionierts auf anhieb.

Was nun noch sehr hilfreich wäre, wäre eine kleine Übersicht, wie man weitere GUI-Elemente im MP nutzen kann. Z.B. das mit dem Search-Keyboard hat lange gedauert bis ich anhand des übrigen Sourcecodes herausgefunden habe wie`s tut - gar nicht so leicht für einen Java- Entwickler der .net nicht kennt ;-)
Xanthophix is offline   Reply With Quote
Old 2005-07-12, 23:14   #3 (permalink)
Webadmin
 
high's Avatar
 
Join Date: Aug 2004
Location: NRW/Germany
Age: 31
Posts: 976
Thanks: 71
Thanked 100 Times in 46 Posts

Country:


Send a message via ICQ to high
Default Re: Probleme mit dem Tutorial "How to write a plugin for Media Portal"

hmm ich würde sagen es ist am besten mal im IRC vorbei zu schaun und dort direkt mit einem Coder zu sprechen. Frodo ist froh über jeden der aktiv codet und wird Dir da sicher weiterhelfen können.
high is offline   Reply With Quote
Old 2005-07-15, 17:35   #4 (permalink)
Portal User
 
Join Date: Feb 2005
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts


Default Re: Probleme mit dem Tutorial "How to write a plugin for Media Portal"

besten Dank für den Tipp. Sollte ich wieder Probleme haben, werde ich mich mal im IRC umhören :-)
Xanthophix is offline   Reply With Quote
Reply

Bookmarks

Tags
dem, tutorial

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


All times are GMT +1. The time now is 06:25.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0 Protected by Akismet Blog with WordPress
Advertisement System V2.6 By   Branden