Results 1 to 4 of 4

Thread: ActiveX - Integrate dumpcpp interfaces

  1. #1
    Join Date
    Oct 2006
    Location
    Germany
    Posts
    84
    Thanks
    5
    Thanked 5 Times in 3 Posts
    Qt products
    Qt4
    Platforms
    Windows

    Default ActiveX - Integrate dumpcpp interfaces

    Hello,
    I'm trying to adjust the volume of my WindowsMediaPlayer ActiveX control.
    Unfortunately, I couldn't find the appropriate methods in QAxWidget::generateDocumentation() but I know they exist. It's actually IWMPSettings::setVolume() where I can adjust the volume.
    Now I used Qt's dumpcpp tool to generate the namespace interface thingies but I have no clue how to use it. The generated .h file has the proper method:

    Qt Code:
    1. class WMPLIB_EXPORT IWMPSettings : public QAxObject
    2. {
    3. public:
    4. IWMPSettings(IDispatch *subobject = 0, QAxObject *parent = 0)
    5. : QAxObject((IUnknown*)subobject, parent)
    6. {
    7. internalRelease();
    8. }
    9.  
    10. //[...]
    11.  
    12. /*
    13.   Property volume
    14.  
    15.   Returns current audio volume
    16.  
    17.   */
    18. inline int volume() const; //Returns the value of volume
    19. inline void setVolume(int value); //Sets the value of the volume property
    20.  
    21. //[...]
    22. };
    To copy to clipboard, switch view to plain text mode 

    And here's how I tried it (inside my subclassed QAxWidget):

    Qt Code:
    1. WMPLib::IWMPSettings *s = 0;
    2. this->queryInterface("{9104D1AB-80C9-4fed-ABF0-2E6417A6DF14}", (void **)&s);
    3. s->setVolume(75);
    To copy to clipboard, switch view to plain text mode 

    (I found the Uuid in the WMP-SDK and also on google) But all I get are runtime errors in s->setVolume() (well of course).

    So am I understanding something wrong or is it really that hard to get it?

    Thank you!

  2. #2
    Join Date
    Oct 2006
    Location
    Germany
    Posts
    84
    Thanks
    5
    Thanked 5 Times in 3 Posts
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: ActiveX - Integrate dumpcpp interfaces

    *bump*

  3. #3
    Join Date
    Jan 2011
    Posts
    3
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: ActiveX - Integrate dumpcpp interfaces

    BUMP !
    I too would like an answer to this

  4. #4
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: ActiveX - Integrate dumpcpp interfaces

    Resurrecting a 4 year old thread is poor netiquette, doubly so when it is a Me Too!

    Read the manual, particularly the Qutlook example.
    Search the forum for "dumpcpp" or "activeqt", there are plenty of (more recent) threads about ActiveQt.
    Ultimately you just use the generated classes like any other.

    When you still cannot work it out, then start your own thread that actually states what the problem is, and what you have tried, and how it fails.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.