unit Unit1;

interface

uses
  Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants, System.Classes, Vcl.Graphics,
  Vcl.Controls, Vcl.Forms, Vcl.Dialogs, Vcl.StdCtrls, NxEdit6;

type
  TForm1 = class(TForm)
    NxGridPicker61: TNxGridPicker6;
    Button1: TButton;
    ListBox1: TListBox;
    procedure Button1Click(Sender: TObject);
    procedure NxGridPicker61SetValue(Sender: TObject; SelectedIndex: Integer; var Value: WideString);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form1: TForm1;

implementation

{$R *.dfm}

procedure TForm1.Button1Click(Sender: TObject);
begin
  NxGridPicker61.AddRow(['Audi', 'Germany']);
  NxGridPicker61.AddRow(['BMW', 'Germany']);
  NxGridPicker61.AddRow(['Chevrloet', 'USA']);
  NxGridPicker61.AddRow(['Citroen', 'France']);
  NxGridPicker61.AddRow(['Fiat', 'Italy']);
  NxGridPicker61.AddRow(['Ford', 'USA']);
  NxGridPicker61.AddRow(['Hyundai', 'South Korea']);
  NxGridPicker61.AddRow(['Mercedes-Benz', 'Germany']);
  NxGridPicker61.AddRow(['Opel', 'Germany']);
  NxGridPicker61.AddRow(['Peugeot', 'France']);
  NxGridPicker61.AddRow(['Toyota', 'Japan']);
  NxGridPicker61.AddRow(['Volvo', 'Sweden']);
end;

procedure TForm1.NxGridPicker61SetValue(Sender: TObject; SelectedIndex: Integer; var Value: WideString);
begin
  ListBox1.Items.Add('Index: ' + IntToStr(SelectedIndex) + ', Value: ' + Value)
end;

end.
