|
Posted by Lokesh Sharma on October 3, 2007, 9:35 am
Please log in for more thread options Hello Mr. Tom,
Thank you very much for your support. I can use
windows media player programmatically. But still the Active X control is not
active.
I did following:
1. To get AxWMPLib.cs, I run following command on Visual
Studio Command prompt.
aximp c:\WINDOWS\system32\wmp.dll /source
2. I added references to 'WMPLib.dll'. Compiler was
giving error so I added reference to 'Microsoft.WindowsCE.Forms'.
3. I added following files in the project to get it
compiled (files are provided with the source code available with the
webcast)
a. AxHost.cs.
b. AxHost.xmta.
c. AxImpSupport.cs
d. AxWMPLib.cs
e. NativeInterfaces.cs
f. OleSite.cs
g. TypeHelper.cs
4. I put the references to
'System.Runtime.InteropServices' and 'AxWMPLib' by writing following code
at start :
using System.Runtime.InteropServices;
using AxWMPLib;
5. I created an instance of
'AxWMPLib.AxWindowsMediaPlayer'.
Still I am unable to use Active X
control. Will you help me to find the problem?
>> Hello Everybody,
>> I am new to C# as well as windows mobile
>> smartphone.
>> I am trying to embed windows media player in my
>> application. I found few good links like
>>
>>
>> http://msdn2.microsoft.com/en-us/library/aa446523.aspx
>>
>> http://msdn2.microsoft.com/en-us/library/aa446515.aspx
>>
>>
>> http://msdn2.microsoft.com/en-us/library/bb249583.aspx
>>
>> http://msdn2.microsoft.com/en-us/library/bb248590.aspx
>>
>> http://msdn2.microsoft.com/en-us/library/bb248593.aspx
>>
>> but still i am unable to do so.
>> I am using Motorola Q device which is having
>> windows
>> media player 10.
>>
>> Can anybody tell me steps to perform to use
>> windows
>> media player in my application.
>>
>> Thanks in anticipation.
>>
>> Thanks and Regards,
>> Lokesh Sharma
>
> I found Alex Feinman's webcast & source code very helpful:
> http://blog.opennetcf.org/afeinman/default,date,2005-08-25.aspx
>
> Regards
> Tom
>
|