# Visual Basic > Xamarin >  i want to learn database prog with xamarin

## genlight

Hi guys, 

I am interested on xamarin but im new and still beginning to learn.  Can you provide simple mysql crud example to check it out and learn by example. tnx

----------


## jmcilhinney

I would suggest that you search first, do what you can with what you find and then ask specific questions about what you don't understand.

https://www.bing.com/search?q=xamari...ZYwzIeBvquxLkY

----------


## genlight

Isnt there a crud sample in codebank?

----------


## jmcilhinney

Maybe, but Xamarin with MySQL is rather specific, so there's no guarantee and, even if there is, what are the chances of the person who posted it seeing this thread and providing a link?  Have you searched the CodeBank forum(s) to see whether you can find one?

Based on what I can find, it seems that CRUD access to MySQL from Xamarin is not possible by default.  It seems that you need to either purchase a commercial ADO.NET provider or create your own web service.

----------


## Prahlad

```
void deleteBtn_Click(object sender, EventArgs e)
        {
            if (crud.delete(selectedItem))
            {
                nameTxt.Text = "";
                adapter = new ArrayAdapter(this, Android.Resource.Layout.SimpleListItem1, names);
                lv.Adapter = adapter;
            }
        }

        void updateBtn_Click(object sender, EventArgs e)
        {
            if(crud.update(nameTxt.Text, selectedItem))
            {
                adapter = new ArrayAdapter(this, Android.Resource.Layout.SimpleListItem1, names);
                lv.Adapter = adapter;
            }
        }

        void addBtn_Click(object sender, EventArgs e)
        {
            if(crud.add(nameTxt.Text))
            {
                nameTxt.Text = "";
                adapter = new ArrayAdapter(this, Android.Resource.Layout.SimpleListItem1, names);
                lv.Adapter = adapter;
            }

        }

        void lv_ItemClick(object sender, AdapterView.ItemClickEventArgs e)
        {
            this.selectedItem = e.Position;
            nameTxt.Text = names[selectedItem].ToString();
        }

    }
}
C#
```

----------


## Prahlad

```
void deleteBtn_Click(object sender, EventArgs e)
        {
            if (crud.delete(selectedItem))
            {
                nameTxt.Text = "";
                adapter = new ArrayAdapter(this, Android.Resource.Layout.SimpleListItem1, names);
                lv.Adapter = adapter;
            }
        }

        void updateBtn_Click(object sender, EventArgs e)
        {
            if(crud.update(nameTxt.Text, selectedItem))
            {
                adapter = new ArrayAdapter(this, Android.Resource.Layout.SimpleListItem1, names);
                lv.Adapter = adapter;
            }
        }

        void addBtn_Click(object sender, EventArgs e)
        {
            if(crud.add(nameTxt.Text))
            {
                nameTxt.Text = "";
                adapter = new ArrayAdapter(this, Android.Resource.Layout.SimpleListItem1, names);
                lv.Adapter = adapter;
            }

        }

        void lv_ItemClick(object sender, AdapterView.ItemClickEventArgs e)
        {
            this.selectedItem = e.Position;
            nameTxt.Text = names[selectedItem].ToString();
        }

    }
}
C#
```

----------

