This is a migrated thread and some comments may be shown as answers.

.NET examples

1 Answer 36 Views
General Discussion
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Sam
Top achievements
Rank 1
Sam asked on 25 Sep 2013, 02:44 PM
Hi,

I've completed a mobile app using Everlive / Icenium - Awesome!
HOWEVER, I need to create an administrative side using .net winforms.

I'm trying to use the example documenation but I am sure I'm missing some of the basics.
Can anyone provide a simple WinForm example binding EverLive data to a Grid?

1 Answer, 1 is accepted

Sort by
0
Accepted
Sam
Top achievements
Rank 1
answered on 26 Sep 2013, 08:28 PM
Okay, 

I managed to get the data to the grid as follows:



private async Task GetActions()
        {
            // TheSWShop Connect to Everlive Database and Pull Actions and Locations.
            try
            {
                var actionCount = await app.WorkWith().Data<Action>().GetCount().ExecuteAsync();
                Debug.WriteLine(actionCount);

                var actionData = await app.WorkWith().Data<Action>().GetAll().ExecuteAsync();
                radGridView1.DataSource = actionData;
            }
            catch (EverliveException ex)
            {
                Debug.WriteLine(ex);
            }
        }


public class Action : DataItem
    {
        private string serialno;
        public string SerialNo
        {
            get
            {
                return this.serialno;
            }
            set
            {
                this.serialno = value;
                this.OnPropertyChanged("SerialNo");
            }
        }
        
        private string location;
        public string Location
        {
            get
            {
                return this.location;
            }
            set
            {
                this.location = value;
                this.OnPropertyChanged("Location");
            }
        }
        private string actiontype;
        public string ActionType
        {
            get
            {
                return this.actiontype;
            }
            set
            {
                this.actiontype = value;
                this.OnPropertyChanged("ActionType");
            }
        }
        private string lotno;
        public string LotNo
        {
            get
            {
                return this.lotno;
            }
            set
            {
                this.lotno = value;
                this.OnPropertyChanged("LotNo");
            }
        }
        
        
    }

Tags
General Discussion
Asked by
Sam
Top achievements
Rank 1
Answers by
Sam
Top achievements
Rank 1
Share this question
or