Re: [gnome-db] how to print selected row in gnome_db_raw_grid?





2008/9/23 paragasu <paragasu gmail com>
> gda_value_stringify(value)

assume that i know, the value return is string, then i can simply use
this function so i can print
(GValue to gchar) the string.  but there is no function to conver
GValue to gint or gfloat..

Yes, there are
g_value_get_int()
g_value_get_float()...
 

the only function i can think of is gda_value_numeric but it doesn't do that.

so assume that i know, that i have a double datatypes inside my table
column, how i can get
the value and assign it in a gdouble variable ?

mydouble = g_value_get_double (value);
 


for example, if gchar,

i can simply
gchar *str;
str = gda_value_stringfy ();

The gda_value_stringify() works for GValue of any type.

Cheers,

Vivien



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]