gtk_statusbar!!




Hi!!
I need help to buid an statusbar...
i create an application with glade...this is the structure.

Ther's a window,with a menu...when i select an option it opens a new window.
I want to open a file list ,li ke this:
file opened:

c:\data\2003.1
c:\data\2003.2

i read each line,and make operations with all the dates inside each one,before
with the first and then with the last.
I want,that during the calculate process...it will be writen in a status
bar---processing c:\data\2003.1..when it finish,tha statusbar has to change to
processing c:\data\2003.2

I tried to do it with this code.

fp=fopen("C:\data\2003.1","r")
while(fscanf(fp,"%s",fichdat)!=EOF)
   {
     g_snprintf(regi,200,"Processing el File:  %s",fichdat);
     gtk_statusbar_push(GTK_STATUSBAR(statusbar2),1,regi);                      
         

      novd=real_estad_fich(fichdat,porcent);
         
     if(novd==1)
      {
        fclose(fp);
        return;
  gtk_statusbar_pop (GTK_STATUSBAR(statusbar2),1);
    }

   }
/***********real_estad_fich is the function that contains all the math
operations i want to do process with each file***********************/


The problem is that onli writes in the statusbar the last file
Processing c:\data\2003.2

can anyone help me??
Thanks a lot





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