ArcGISRuntimeXamarin.SamplesViewController.SamplesDataSource.RowSelected C# (CSharp) Method

RowSelected() public method

public RowSelected ( UITableView tableView, NSIndexPath indexPath ) : void
tableView UITableView
indexPath NSIndexPath
return void
            public override void RowSelected(UITableView tableView, NSIndexPath indexPath)
            {
                try
                {
                    var item = data[indexPath.Row];
                    var sampleName = (item as SampleModel).SampleName;
                    var sampleNamespace = (item as SampleModel).SampleNamespace;

                    Type t = Type.GetType(sampleNamespace + "." + sampleName);
                    UIViewController vc = Activator.CreateInstance(t) as UIViewController;

                    controller.NavigationController.PushViewController(vc, true);
                }
                catch (Exception ex)
                {
                    Console.WriteLine(ex.Message);
                }
            }
        }