Results 1 to 1 of 1

Thread: QAxWidget and C#

  1. #1
    Join Date
    May 2011
    Posts
    2
    Qt products
    Qt4
    Platforms
    Windows

    Default QAxWidget and C#

    Hi,

    I'm trying to work with the QAxWidget. I'm very newbie, but I find out that is necessary to use the setControl method, and call the GUID of a dll.

    At the Visual Studio, creating a Qt project, I can see a list of COM objects, but under Qt Creator I don't have that list.

    What is that list, and how can I add a dll at that list of GUIDs acessible under Qt ?

    Yet this way, I created a very simple dll in C#, with the code bellow

    Qt Code:
    1. namespace dll_teste3
    2. {
    3. [Guid("E8EB6383-ABAC-448A-8E05-8CADDB3A5712")]
    4. interface IMyDotNetInterface
    5. {
    6. int teste();
    7. }
    8.  
    9. [ClassInterface(ClassInterfaceType.None)]
    10. [Guid("A2E86BE9-0F94-43DF-B1C6-2FC3056DA028")]
    11. class MyDotNetClass : IMyDotNetInterface
    12. {
    13. public MyDotNetClass()
    14. {}
    15. public int teste()
    16. {
    17. return 10;
    18. }
    19. }
    20. }
    To copy to clipboard, switch view to plain text mode 

    How can I wrap a MyDotNetClass under Qt, and call the teste method ? I guess the QAxWidget is the right way.

    Using a QLibrary is another way, but I can't access the class or methods.

    Excuse my extensive question, but I don't found a nice doc about the first steps of QAxWidget use.

    If anyone can answer the example would be a very nice first step.

    Thanks in advance,
    Vitor
    Last edited by vxmontes; 3rd August 2011 at 18:52.

Similar Threads

  1. QGLWidgets + QAXWidget
    By Pablo in forum Newbie
    Replies: 0
    Last Post: 22nd January 2010, 14:03
  2. QAxWidget
    By rajeshs in forum Qt Programming
    Replies: 1
    Last Post: 5th September 2008, 05:13
  3. QAxWidget
    By chak_med in forum Newbie
    Replies: 1
    Last Post: 10th September 2006, 20:05
  4. QAxWidget Properties
    By ToddAtWSU in forum Newbie
    Replies: 1
    Last Post: 13th February 2006, 17:45
  5. QAxWidget
    By ToddAtWSU in forum Newbie
    Replies: 2
    Last Post: 3rd February 2006, 17:29

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.