Calling VB6 function from javascript in ASP

Discussion in 'Javascript' started by Sipho, Feb 8, 2005.

  1. Sipho

    Sipho Guest

    Hi,

    I need to instantiate a VB6 function and call it from javascript in
    ASP.

    <script language='javascript'>
    function onScheduleTask() {
    var ocuScheduler
    ocuScheduler = new ActiveXObject("CCUtility.CU_ScheduledTaskQueue")

    ocuScheduler.AddScheduledTask(SCHEDTASKTYPE_POLLEDQUEUED)
    }

    </script>

    looking at the code above :
    ->("CCUtility.CU_ScheduledTaskQueue") is a VB6 function running under
    COM+
    ->ocuScheduler.AddScheduledTask(SCHEDTASKTYPE_POLLEDQUEUED)- here I'm
    trying to call that function passing a parameter.

    I get an error message when I try to execute the code : "Automation
    server can't create object"

    Please help.
     
    Sipho, Feb 8, 2005
    #1
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.