Announcement

Collapse
No announcement yet.

Script error: Wrong number of arguments or invalid property assignment

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Script error: Wrong number of arguments or invalid property assignment

    I just installed mcsDeviceGrid from the updater in to Homeseer 2.0 build 1955 and I get the error below when navigating to the home page. The error itself shows up in the web page, no error in the log. I am using mcsDeviceGrid version 1.1.0.1 from the updater.

    Script error: Wrong number of arguments or invalid property assignment: 'hs.Getplugins'
    Response.Write hs.Getplugins("mcsDeviceGrid").DeviceGridASP(request, response)


    Anyone have any ideas? I just migrated to Homeseer 2.0 and it maybe something that I am doing wrong, anyone else have any issues?

    Thanks...
    Billy Draper

    #2
    Each HS2 version seems to want a differnt method to get access to the plugin. This is the pattern I just submitted for mcsSprinklers to handle 3 versions. The file you will be changing is in the HTML folder and maybe mcsDeviceGrid subfolder with the name mcsDeviceGrid.asp

    PHP Code:
    <% 
    on error resume next
    response
    .write hs.GetPlugins("mcsDeviceGrid").DeviceGridASP(requestresponse)
    if 
    err.number <> 0 then
        err
    .clear
        response
    .write hs.Plugin("mcsDeviceGrid").DeviceGridASP(requestresponse)
        if 
    err.number <> 0 then
            err
    .clear
            set col 
    hs.GetPlugins
            
    for each c in col
                
    if c.name "mcsDeviceGrid" then
                    response
    .write c.DeviceGridASP(requestresponse)
                    exit for
                
    end if
            
    next
            set col 
    Nothing
        End 
    if
    End if
    %> 

    Comment


      #3
      Wow Thanks Michael for the quick reply... I'm at work right now and will look at this first thing when I get home, right after I kiss the wife.
      Billy Draper

      Comment


        #4
        Great work Michael. I pasted the code into mcsDeviceGrid.asp and it worked as expected.

        I really apprecite everything. Now I guess I need to read the docs to find out what the different colors mean.
        Billy Draper

        Comment

        Working...
        X