Question: using activex controls on a gadget

Hi, i am leroy (spydaz)

i have recently read the tutorial on windows sidebar gadgets. and the tutorial on sidebar gadgets...

Firstly i use VB6 and Ms.Office.2003. i would like to begin building gadgets..

Is it possible to use activex controls on a sidebar gadget. As with regular WebDesign / HTML. ie design the control in VB6 Mycontrol.OCX and use it in a sidebar gadjet. ie: mini Database Form Project... as i saw with the templates available as samples the were all refferenceing then new architecture .net *ExpressEditions.




Answer this question

Question: using activex controls on a gadget

  • Tad McClellan

    fathi S. Elashery wrote:

    hi

    i have a problem in registering the com component

    can any one send me how to register .dll file if it is different of the previose version

    thanks

    Fathi S. Elashery



    I use regasm /register /codebase [path to dll]
    (its for .Net dll's, don't know for other languages)

  • jdrawmer

    Yes, I also think so....
    the important code is in the com, the javascript is not so important, that it should be protected.

    But I'm new to JavaScript/COM....
    I can call com functions in my dll out of the js code, but not the other way.
    My dll is coded in c#. Are there any good examples my activex does not have a user interface, only logic!
    Whats the right way to open it, in the javascript side

    I use: object = new activeXObject("myAX");

    so, how do I call code in the javascript out of the dll

    thanks!

  • Murali Medisetti

    It all depends on how protective you are of your code - and which you find easier to code for. If your app is CPU intensive, then putting it inside the COM may well use less CPU resources.

    I personally code as much as possible in JavaScript, and just put necessary code into ActiveX COM.

  • vbjunkie

    object.<function>

    eg:

    var DSXLib = new ActiveXObject("DSXLib.DSX");
    ...
    sounds[0] = DSXLib.LoadSound(gadgetPath + "\\sounds\\explode1.wav", false, 1, 11025, 8);

  • silvio_at

    yes, in this way I know how to call.
    But how do I call JS functions out of the c# dll

    is it possible to return lists, structs from a com function

    thx

  • algoaddict

    You can use ActiveX controls with your gadget. If you're providing your own ActiveX control, you should write your own installer that installs and registers the ActiveX control, and copies the gadget files to a subdirectory of "\Program Files\Windows Sidebar\Shared Gadgets"
  • deltaspecops99

    Hello,

    I have a simmilar problem...
    My question is, if it is better, to develop the whole gadget as a big activex component (its a relativ complex application, but small enough for the sidebar)
    Or code only the application logic as an activex com and do the whole design in javascript thats communicate with the ax component.

    thanks and greets from germany!

  • eldiener

    ok, thanks!
    But I think it would be easier to adopt it to the sidebar design, if the whole ui is coded in html/javascript, isn't it

  • Strakian

    Have a look at sidebarAlert (you'll need an account on AeroXperience to download it), it has a C++ function that calls a JavaScript function.

    You can pass the JavaScript function address by passing the function name, what you have to do in C# to then call that, I'm not sure.

  • Bill Thoreson

    hi

    i have a problem in registering the com component

    can any one send me how to register .dll file if it is different of the previose version

    thanks

    Fathi S. Elashery



  • Question: using activex controls on a gadget