(no subject)
- From: "Ernesto Ruiz" <ruizernesto hotmail com>
- To: gtk-list gnome org
- Subject: (no subject)
- Date: Sun, 13 Jan 2002 15:40:25
Hi, I have a huuuugeee problem using the combo box.
I'm making a project using FILES and I wanted to assign elements of a file
to the combo box, it's working, but the last element of the file I don't
know how is twice on the combo box. Here's the code:
void asignacombo(char *nombarch)
{
fd=fopen(nombarch,"r");
if (fd==NULL)
{
exit(1);
}
else
{
while(!feof(fd))
{
fread(&n1,sizeof(struct nom),1,fd);
if (strcmp(acum,n1.nombre)!=0)
{
strcpy(acum,n1.nombre);
glist = g_list_append (glist, (g_strdup(acum)));
gtk_combo_set_popdown_strings (GTK_COMBO (combo1), glist);
}
}
fclose(fd);
}
}
Thanks for the Help
Ernesto Ruiz
_________________________________________________________________
Join the world’s largest e-mail service with MSN Hotmail.
http://www.hotmail.com
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]