Quantcast
Channel: Azure Mobile Apps forum
Viewing all articles
Browse latest Browse all 3756

Exception on Update azure mobile services data table

$
0
0

I am trying to develop an app for windows phone using azure mobile services. I am using authentication services provided by azure portal. After authentication the user needs to enter some data like his name, email id etc. Also I have restricted one user to use only one row by using insert script.  I am Taking Input using multiple pages. When I am trying to update the row at the end of second page I am getting an exception

My Table:

public class myTabble
        {
            public string Id { get; set; }

            [JsonProperty(PropertyName = "name")]
            public string name { get; set; }

            [JsonProperty(PropertyName = "age")]
            public int age { get; set; }

            [JsonProperty(PropertyName = "fname")]
            public string fname { get; set; }

            [JsonProperty(PropertyName = "street")]
            public string street { get; set; }

            [JsonProperty(PropertyName = "college")]
            public string college { get; set; }
        }

my update Function on the Second page button

 private async void UpdateCheckedTodoItem(myTabble item)
            {
                await todoTable.UpdateAsync(item);
            }

            
            private void save_Click(object sender, RoutedEventArgs e)
            {

                myTabble item= new myTabble();
                try
                {

                    

                    item.street = street.Text;

                    item.college = college.Text;

                    UpdateCheckedTodoItem(item);
                    
                }
                catch
                {
                    MessageBox.Show("Invalid input");
                }
            }

I am getting exception on this line

await todoTable.UpdateAsync(item);

 


Viewing all articles
Browse latest Browse all 3756

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>