Ejemplo n.º 1
0
        public async void showTotalPoint()
        {
            GetUserTotalPoint getUserPoint = new GetUserTotalPoint();

            userTotalPoint = await getUserPoint.getUserTotalPoint(Xamarin.Forms.Application.Current.Properties["email"].ToString());

            if (!string.IsNullOrEmpty(userTotalPoint))
            {
                userPoint.Text = userTotalPoint;
            }
            else
            {
                userPoint.Text = "0";
            }
        }
Ejemplo n.º 2
0
        public async void showTotalPoint()
        {
            GetUserTotalPoint getUserPoint = new GetUserTotalPoint();

            userTotalPoint = await getUserPoint.getUserTotalPoint(Xamarin.Forms.Application.Current.Properties["email"].ToString());

            if (!string.IsNullOrEmpty(userTotalPoint) && int.Parse(userTotalPoint) >= 0)
            {
                userPoint.Text = userTotalPoint;
            }
            else if (!string.IsNullOrEmpty(userTotalPoint) && userTotalPoint == "-1")
            {
                await DisplayAlert("訊息", "取得使用者點數資料失敗!", "OK");
            }
            else
            {
                userPoint.Text = "0";
            }
        }