Example #1
0
        public string SetCamera(string json)
        {
            if (_channel == null)
            {
                return(cNeedConnect);
            }

            try
            {
                if (_channel.SetCamera(json))
                {
                    return(cSuccess);
                }
            }
            catch (Exception ex)
            {
                if (ex is FaultException <EarthNamedpipeFault> )
                {
                    return((ex as FaultException <EarthNamedpipeFault>).Message);
                }
                else
                {
                    return(ex.Message);
                }
            }

            return(cFailed);
        }
Example #2
0
        public bool SetCamera(string json)
        {
            if (_channel == null)
            {
                return(false);
            }

            try
            {
                if (_channel.SetCamera(json))
                {
                    return(true);
                }
                else
                {
                    return(false);
                }
            }
            catch
            {
                return(false);
            }
        }