Westwind.WebConnection.wwDotNetBridge.InvokeStaticMethodAsync C# (CSharp) Method

InvokeStaticMethodAsync() public method

Invokes a method on a new thread and fires OnCompleted and OnError events on a passed in callback object.
public InvokeStaticMethodAsync ( object callBack, string typeName, string method ) : void
callBack object /// A callback object that has to have two methods: /// OnCompleted(lvResult, lcMethod) /// OnError(lcErrorMsg,loException, lcMethod) ///
typeName string
method string
return void
        public void InvokeStaticMethodAsync(object callBack, string typeName, string method, params object[] parameters)
        {
            if (callBack == null || string.IsNullOrEmpty(method))
                throw new ApplicationException("You have to pass a callback object and method name.");

            var t = new Thread(_InvokeMethodAsync);

            var parms = new object[5];
            parms[0] = callBack;
            parms[1] = typeName;
            parms[2] = method;
            parms[3] = parameters;
            parms[4] = true; // isStatic
            t.Start(parms);
        }
wwDotNetBridge