Esempio n. 1
0
        protected async override Task <JObject[]> ExecuteAsync(AsyncCodeActivityContext context)
        {
            var ignoreErrors = IgnoreErrors.Get(context);
            var collection   = Collection.Get(context);
            var querystring  = QueryString.Get(context);
            var projection   = Projection.Get(context);
            var top          = Top.Get(context);
            var skip         = Skip.Get(context);

            if (top < 1)
            {
                top = 100;
            }
            if (skip < 0)
            {
                skip = 0;
            }
            var orderby = Orderby.Get(context);

            if (string.IsNullOrEmpty(collection))
            {
                collection = "entities";
            }
            JObject[] result = null;
            result = await global.webSocketClient.Query <JObject>(collection, querystring, projection, top, skip, orderby);

            System.Windows.Forms.Application.DoEvents();
            return(result);
        }