예제 #1
0
        protected override async void OnCreate(Bundle bundle)
        {
            base.OnCreate(bundle);

            // Set our view from the "main" layout resource
            SetContentView(Resource.Layout.Activity_To_Do);  //change to fit

            CurrentPlatform.Init();

            // await InitLocalStoreAsync();

            // Get the Mobile Service sync table instance to use
            var toDoTable = client.GetSyncTable <GuiSettings> ();

            //textNewToDo = FindViewById<EditText> (Resource.Id.textNewToDo);

            // Create an adapter to bind the items with the view
            adapter = new Adapters.GuiSettingsAdapter(this, Resource.Layout.Row_List_To_Do);//edit for matching view resource
            var listViewGuiSettings = FindViewById <ListView> (Resource.Id.listViewToDo);

            listViewGuiSettings.Adapter = adapter;

            // Load the items from the Mobile Service
            OnRefreshItemsSelected();
        }
        protected override async void OnCreate (Bundle bundle)
        {
            base.OnCreate (bundle);

            // Set our view from the "main" layout resource
            SetContentView (Resource.Layout.Activity_To_Do); //change to fit

            CurrentPlatform.Init ();

           // await InitLocalStoreAsync();

            // Get the Mobile Service sync table instance to use
            var toDoTable = client.GetSyncTable <GuiSettings> ();

            //textNewToDo = FindViewById<EditText> (Resource.Id.textNewToDo);

            // Create an adapter to bind the items with the view
            adapter = new Adapters.GuiSettingsAdapter(this, Resource.Layout.Row_List_To_Do);//edit for matching view resource 
            var listViewGuiSettings = FindViewById<ListView> (Resource.Id.listViewToDo);
            listViewGuiSettings.Adapter = adapter;

            // Load the items from the Mobile Service
            OnRefreshItemsSelected ();
        }