+
+struct spreadsheet *sp = NULL;
+GtkWidget *combo_box;
+
+static void
+on_clicked (GtkButton *button, gpointer data)
+{
+ struct ccase *c;
+ gint x = gtk_combo_box_get_active (GTK_COMBO_BOX (combo_box));
+ struct casereader *reader ;
+ struct spreadsheet_read_info ri;
+ struct spreadsheet_read_options opts;
+
+ g_print( "%s %d\n", __FUNCTION__, x);
+
+ opts.sheet_index = x + 1;
+ opts.cell_range = NULL;
+ opts.sheet_name = NULL;
+
+ ri.read_names = TRUE;
+ ri.asw = -1;
+
+ reader = gnumeric_make_reader (sp, &ri, &opts);
+ for (;
+ (c = casereader_read (reader)) != NULL; case_unref (c))
+ {
+ const double val = case_data_idx (c, 0)->f;
+ printf ("%g\n", val);
+ }
+}
+