Example #1
0
        private async void cmdValue_Click(object sender, EventArgs e)
        {
            SvcRestClient client =
                new SvcRestClient(new Uri("http://localhost/SwaggerWebApp"),
                                  new AnonymousCredential());
            var result = client.Values.GetByid(1);

            MessageBox.Show(result);
        }
Example #2
0
        private async void cmdUpdate_Click(object sender, EventArgs e)
        {
            SvcRestClient client =
                new SvcRestClient(new Uri("http://localhost/SwaggerWebApp"),
                                  new AnonymousCredential());

            client.Values.PutByidvalue(1, "New Value");

            MessageBox.Show("Change Completed!");
        }
Example #3
0
        private async void cmdAllValues_Click(object sender, EventArgs e)
        {
            SvcRestClient client =
                new SvcRestClient(new Uri("http://localhost/SwaggerWebApp"),
                                  new AnonymousCredential());
            var result = client.Values.Get();

            foreach (var x in result)
            {
                MessageBox.Show(x);
            }
        }