home
products
contribute
download
documentation
forum
Home
Forums
New posts
Search forums
What's new
New posts
All posts
Latest activity
Members
Registered members
Current visitors
Donate
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Search forums
Search titles only
By:
Menu
Log in
Register
Navigation
Install the app
Install
More options
Contact us
Close Menu
Forums
MediaPortal 1
Development
General Development (no feature request here!)
How to catch keypresses
Contact us
RSS
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="pilehave" data-source="post: 300890" data-attributes="member: 71550"><p>Thank you, I think I'm getting wiser <img src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7" class="smilie smilie--sprite smilie--sprite1" alt=":)" title="Smile :)" loading="lazy" data-shortname=":)" /></p><p></p><p>But when I try to move on in my code, I keep getting this error:</p><p></p><p>[CODE]The type or namespace name 'GUIDialogOK' could not be found (are you missing a using directive or an assembly reference?)[/CODE]</p><p></p><p>In the top of my script I have this:</p><p></p><p>[CODE]using System;</p><p>using System.Runtime.InteropServices;</p><p>using System.Windows.Forms;</p><p>using System.Web;</p><p>using MediaPortal.Configuration;</p><p>using MediaPortal.Util;</p><p>using MediaPortal.GUI.Library;[/CODE]</p><p></p><p>(The above is stolen from another plugin)</p><p></p><p>I have added references to Core.dll, Utils.dll and RemotePlugins.dll (I think I'll need that one).</p><p></p><p>The code that triggers the error in the debugger is this:</p><p></p><p>[CODE] public override void OnAction(MediaPortal.GUI.Library.Action action)</p><p> {</p><p> char mumbojumbo = (char)action.m_key.KeyChar;</p><p> OnButtonOne(mumbojumbo);</p><p></p><p> }</p><p></p><p> private void OnButtonOne(char whatever)</p><p> {</p><p> GUIDialogOK standbyMessage = (GUIDialogOK)GUIWindowManager.GetWindow((int)GUIWindow.Window.WINDOW_DIALOG_OK);</p><p> standbyMessage.Reset();</p><p> standbyMessage.SetHeading("Testing popup");</p><p> standbyMessage.SetLine(1, "whatever...");</p><p></p><p> standbyMessage.DoModal(MediaPortal.GUI.Library.GUIWindowManager.ActiveWindow);</p><p></p><p></p><p> }[/CODE]</p><p></p><p>Could you perhaps lead me on the way again? I'm quite new to this and have only done a little Visual Basic many years ago, but believe I know my way around PHP and also ASP...so should be able to learn on the way!</p><p></p><p>Thank you.</p></blockquote><p></p>
[QUOTE="pilehave, post: 300890, member: 71550"] Thank you, I think I'm getting wiser :) But when I try to move on in my code, I keep getting this error: [CODE]The type or namespace name 'GUIDialogOK' could not be found (are you missing a using directive or an assembly reference?)[/CODE] In the top of my script I have this: [CODE]using System; using System.Runtime.InteropServices; using System.Windows.Forms; using System.Web; using MediaPortal.Configuration; using MediaPortal.Util; using MediaPortal.GUI.Library;[/CODE] (The above is stolen from another plugin) I have added references to Core.dll, Utils.dll and RemotePlugins.dll (I think I'll need that one). The code that triggers the error in the debugger is this: [CODE] public override void OnAction(MediaPortal.GUI.Library.Action action) { char mumbojumbo = (char)action.m_key.KeyChar; OnButtonOne(mumbojumbo); } private void OnButtonOne(char whatever) { GUIDialogOK standbyMessage = (GUIDialogOK)GUIWindowManager.GetWindow((int)GUIWindow.Window.WINDOW_DIALOG_OK); standbyMessage.Reset(); standbyMessage.SetHeading("Testing popup"); standbyMessage.SetLine(1, "whatever..."); standbyMessage.DoModal(MediaPortal.GUI.Library.GUIWindowManager.ActiveWindow); }[/CODE] Could you perhaps lead me on the way again? I'm quite new to this and have only done a little Visual Basic many years ago, but believe I know my way around PHP and also ASP...so should be able to learn on the way! Thank you. [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
MediaPortal 1
Development
General Development (no feature request here!)
How to catch keypresses
Contact us
RSS
Top
Bottom