Announcement

Collapse

Contacting HomeSeer This Week

HomeSeer is open and operational this week. All orders are being processed and shipped as usual. However, some staff are working from home. If you need to contact HomeSeer for support or customer service, please use our Email or Chat options. https://homeseer.com/contact-us/
See more
See less

Cant control my AVR

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

  • Cant control my AVR

    I am not sure what i'm doing wrong. or what I'm missing. Can someone help? When I run this script (AVRDVD.vb):


    Sub Main(ByVal parms As Object)
    Dim theResponse As String = ""
    theResponse = hs.Plugin("BLDenon").SendRawCommand("SIDVD")
    hs.writelog("Info", "The response for the command is: HTPC" & theResponse)
    theResponse = Nothing
    End Sub

    I get this error:

    Scripting runtime error: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. --- System.NullReferenceException: Object variable or With block variable not set. at Microsoft.VisualBasic.CompilerServices.Symbols.Container..ct or(Object Instance) at Microsoft.VisualBasic.CompilerServices.NewLateBinding.LateGe t(Object Instance, Type Type, String MemberName, Object[] Arguments, String[] ArgumentNames, Type[] TypeArguments, Boolean[] CopyBack) at scriptcode15.scriptcode15.Main(Object parms) --- End of inner exception stack trace --- at System.RuntimeMethodHandle._InvokeMethodFast(Object target, Object[] arguments, SignatureStruct& sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner) at System.RuntimeMethodHandle.InvokeMethodFast(Object target, Object[] arguments, Signature sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner) at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean skipVisibilityChecks) at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) at System.Reflection.MethodBase.Invoke(Object obj, Object[] parameters) at Scheduler.VsaScriptHost.Invoke(String ModuleName, String MethodName, Object[] Arguments)

  • #2
    What version of the plugin are you using in HS3?
    It it is the newest build then you will need to add the receiver number as the first parameter.

    Code:
    Sub Main(ByVal parms As Object)
        Dim theResponse As String = ""
        theResponse = hs.PluginFunction("BLDenon", "", "SendRawCommand", new Object(){1,"SIDVD"})
        hs.writelog("Info", "The response for the command is: HTPC" & theResponse)
        theResponse = Nothing 
    End Sub
    Cheers,
    Bob
    Web site | Help Desk | Feature Requests | Message Board

    Comment


    • #3
      this is the 1.7 version in Homeseer PRO 2. I am trying to see if I can get this working before I take the plunge to purchase. I still have not fully migrated to HS3 for a production server.

      Comment


      • #4
        I got this sorted out, thanks for the reply. I will be purchasing this by the end of the week. Thank you for the option of a free upgrade for HS3, it is appreciated.

        Comment

        Working...
        X