예제 #1
0
        public async void OnEnteredNewActivity(string activityName)
        {
            var item = new ActivityItem()
            {
                Name = activityName, RecentlyDate = DateTime.Now
            };
            var resItem = await mSqlite.AddActivityAsync(item);

            if (resItem != null)
            {
                mListAdapter.Add(resItem);
                ToastManager.ShowLongTime(Activity, Resource.String.toast_success_added_activity);
            }
            else
            {
                ToastManager.ShowLongTime(Activity, Resource.String.toast_failed_add_activity);
            }
        }