Forum Xamarin.Android


The Xamarin Forums have officially moved to the new Microsoft Q&A experience. Microsoft Q&A is the home for technical questions and answers at across all products at Microsoft now including Xamarin!

To create new threads and ask questions head over to Microsoft Q&A for .NET and get involved today.

Fill Gridview from Datatable sql server

i have connection between Xamarin android with web service i need fill gridview or any tools from sql server table

now everything is ok but i need fill gridview with data

namespace AndroidWebService
[Activity(Label = "orderstatus", MainLauncher = true, Icon = "@drawable/icon")]
public class orderstatus : Activity

    protected override void OnCreate(Bundle bundle)

        // Set our view from the "main" layout resource

        // Get our button from the layout resource,
        // and attach an event to it
        Button butSearch = FindViewById<Button>(Resource.Id.butSearch);

        butSearch.Click += butSearch_Click;


    private void butSearch_Click(object sender, EventArgs e)
        var JO = FindViewById<EditText>(Resource.Id.JO);
        var QtqSlit = FindViewById<EditText>(Resource.Id.QtqSlit);

        selling.WebServiceDB ws = new selling.WebServiceDB();
        ws.OrderStatusCompleted += Ws_OrderStatusCompleted;

    private void Ws_OrderStatusCompleted(object sender, selling.OrderStatusCompletedEventArgs e)
        var QtqSlit = FindViewById<EditText>(Resource.Id.QtqSlit);
        var QtyPcs = FindViewById<EditText>(Resource.Id.QtyPcs);
        var GridView = FindViewById<GridView>(Resource.Id.gridView1);
        string msg = "";
        if (e.Result.QtqSlit.ToString().Equals("0"))
           msg = e.Result.Message;

            QtqSlit.Text = "" + e.Result.QtqSlit;
            QtyPcs.Text = "" + e.Result.QtyPcs;
        var callDialog = new AlertDialog.Builder(this);
        callDialog.SetNeutralButton("Ok", delegate {




Sign In or Register to comment.