Author | Topic: extrange behaviour !!! fui testigo | |
---|---|---|
Jorge L | extrange behaviour !!! fui testigo on Sun, 04 Apr 2010 18:28:19 -0300 hello to all Hi to all when i test my program..... i have open a dbf with dbu (compiled with xbase....) in exclusive mode ! when my program trie open this dbf in shared mode, when the aperture fail i run dbcloseall() command to quit to my aplication and giveit "internal structure corrupted" all cases that i run again the program with the same situation, work fine ! oError:genCode : 41,00 oError:operation : DbCloseAll oError:osCode : 0,00 oError:severity : 2,00 oError:subCode : 5,00 regards | |
Jos Luis Otermin [Alaska Software] | Re: extrange behaviour !!! fui testigo on Fri, 07 May 2010 14:02:43 -0300 Hi Jorge, In this case send the code that causes the extrange behaviour to our Technical Support, so it should be better for all of us to study the situation where arises the problem. Other than that, it's very nice to see you swimming in the forums Hope you have a nice weekend. Jos Luis Otermin Alaska Software Soporte Tcnico -------------------------------------------------------------------- Foros de Usuarios: news://news.alaska-software.com Pgina Web: http://www.alaska-software.com Base de Conocimientos en la Web: http://www.alaska-software.com/kbase.shtm Oficina en Europa: Fax: +49 (0) 61 96 - 77 99 99 23 Oficina en EEUU: Fax: +1 (646) 218 1281 -------------------------------------------------------------------- "Jorge L" <jlborlando@way.com.ar> escribi en el mensaje news:1796f9a2$1effb409$5f5fa@news.alaska-software.com... > hello to all > > Hi to all > > when i test my program..... > > i have open a dbf with dbu (compiled with xbase....) in exclusive mode ! > > when my program trie open this dbf in shared mode, when the aperture fail > i run dbcloseall() command to quit to my aplication > and giveit "internal structure corrupted" > all cases that i run again the program with the same situation, work fine > ! > > oError:genCode : 41,00 > oError:operation : DbCloseAll > oError:osCode : 0,00 > oError:severity : 2,00 > oError:subCode : 5,00 > > regards > | |
Jorge L | Re: extrange behaviour !!! fui testigo on Sat, 08 May 2010 00:33:04 -0300 Hi Is it correct that dbcloseall work badly idependet if i write good or bad the programs? On your interest, the point is that i do not have a specific routine that generates the mistake i understand that everything what is unmanageable can encapsulate with a begin sequence, but to my opinion it is like to hide the land under the carpet , but it is not the place to which i want to come ----------------------------- José estoy tratando de cerrar mi aplicación con error cero, lo que me ha llevado a poner un LOG en varias partes del programa a fin de visualizar y descubrir cualquier "fleco" mio que ande dando vueltas. te adjunto el fatal.log (xppfatal.log), para que veas que la recursividad del error se da por el reviente del dbcloseall() cuando este se ejecuta (entiendo que no se visualiza, pero confio en que me creas), que justamente tienen el _quit() y el errorsys . tambien está el programa que genera el error (facturamiszei.prg bastante curioso el lugar que revienta,teniendo en cuenta que 4 terminales pueden llegar a imprimir hasta unas 600 facturas diarias) entiendo que la rutina del error es mejorable y así evitar y/o controlar la recursividad, pero no nos olvidemos del punto, el dbcloseall() no deja de reventar y vuelvo a preguntar, es correcto ? te cuento.... siguiendo al dbcloseall() con el dbcloseall_() , ahí veo que bases no se pudieron cerrar y ahi observo que cuando el dbcloseall() revienta, si hago un dbclosearea(), área por área, el dbclosearea() no retorna NIL sino que retorna "" para 1 o a lo sumo 2 bases punto y aparte, y para terminar... además le agregue un LOG a un EXIT procedure (_quit.prg) para seguir todo lo que no pasa por el xppfatal ni por el xpperror esta instancia me ha dejado bastante sorprendido en las salidas no esperadas que se generan. si te parece te paso un LOG y el proyecto entero para que veas esas partes en la que salta, quizas tengan explicación pero prefiero aprovechar y hacer un encuentro y discutirlo en persona te mando un gran abrazo "José Luis Otermin [Alaska Software]" <jose.otermin@alaska-software.com> escribió en el mensaje de noticias news:7aed84e8$7b5626c3$37490@news.alaska-software.com... > Hi Jorge, > > In this case send the code that causes the extrange behaviour to our > Technical Support, so it should be better for all of us to study the > situation where arises the problem. > > Other than that, it's very nice to see you swimming in the forums > > Hope you have a nice weekend. > > José Luis Otermin > Alaska Software > Soporte Técnico > -------------------------------------------------------------------- > Foros de Usuarios: news://news.alaska-software.com > Página Web: http://www.alaska-software.com > Base de Conocimientos en la Web: http://www.alaska-software.com/kbase.shtm > Oficina en Europa: Fax: +49 (0) 61 96 - 77 99 99 23 > Oficina en EEUU: Fax: +1 (646) 218 1281 > -------------------------------------------------------------------- > > > "Jorge L" <jlborlando@way.com.ar> escribió en el mensaje > news:1796f9a2$1effb409$5f5fa@news.alaska-software.com... >> hello to all >> >> Hi to all >> >> when i test my program..... >> >> i have open a dbf with dbu (compiled with xbase....) in exclusive mode ! >> >> when my program trie open this dbf in shared mode, when the aperture fail >> i run dbcloseall() command to quit to my aplication >> and giveit "internal structure corrupted" >> all cases that i run again the program with the same situation, work fine >> ! >> >> oError:genCode : 41,00 >> oError:operation : DbCloseAll >> oError:osCode : 0,00 >> oError:severity : 2,00 >> oError:subCode : 5,00 >> >> regards >> > > > error.txt fatal.log FACTURAMISZEI.prg _Quit.prg dbCloseAll_.prg | |
AUGE_OHR | Re: extrange behaviour !!! fui testigo on Sat, 08 May 2010 06:42:16 +0200 hi, ok , now found Facturamiszei.PRG : 1.) Set( _SET_DEVICE, 'PRINTER' ) Set( _SET_PRINTFILE, xPrn ) hm .. i think this is not enough SET CONSOLE OFF SET PRINTER TO LPT2 SET PRINT ON IF Set2FILE() SET PRINTER TO C:\print\kuplz.prn ENDIF 2.) @ 0,0 Say tINITPRN try this ?? CHR( 27 ) + CHR( 64 ) ?? CHR( 27 ) + CHR( 80 ) + CHR( 15 ) SET DEVICE TO PRINT 3.) Set( _SET_DEVICE, 'SCREEN' ) Set( _SET_PRINTFILE, '' ) this is my "out" SET CONSOLE OFF SET PRINT ON EJECT ?? CHR( 18 ) ?? CHR( 27 ) + CHR( 80 ) ?? CHR( 27 ) + CHR( 64 ) SET PRINTER TO LPT1 SET PRINT OFF IF Set2FILE() SET PRINTER TO ENDIF SET DEVICE TO SCREEN SET CONSOLE ON *** about : BEGIN SEQUENCE / RECOVER after RECOVER 1st you have to "restore" your old Errorblock bSaveError := ErrorBlock() DO WHILE .T. ErrorBlock( {|e| Break(e)} ) BEGIN SEQUENCE ... EXIT RECOVER ErrorBlock( bSaveError ) ... LOOP / RETURN .F. / QUIT END SEQUENCE ENDDO ErrorBlock( bSaveError ) so you got those recursive Entry in XppFatal.log i see no Xbase++ BUG, only not working Code ... greetings by OHR Jimmy | |
Jorge L | Re: extrange behaviour !!! fui testigo on Sat, 08 May 2010 09:14:14 -0300 Hi Jimmy thanks to the advice, about the use of errorblock() i have the clause "recover using".... in this case i don´t want to use it, but in other cases, ofcourse then, > so you got those recursive Entry in XppFatal.log > i see no Xbase++ BUG, only not working Code ... you say me that i use bad begin sequence, dbcloseall() fail and dbclosearea() giveme empty string ? i say again, this error not ocurr ever, only sometimes.... the point that i try to show is very specific, in fact i can handle and control it, only it worries me to have to control what supposedly is controlled and is there that generates a great emptiness then i hange at the time my question.... going out of the dbcloseall (), the manual says that dbclosearea () it must return NIL then, why "dbclosearea ()" returns empty string instead of nil ? Say to me if it is because i use badly the begin sequence or beacouse i sending badly the characters to the printer ? jimmy, thank you for your worry and participation and i' m be very grateful for possessing you regards "AUGE_OHR" <AUGE_OHR*AT*WEB.DE> escribió en el mensaje de noticias news:4239efaf$982bc82$41a53@news.alaska-software.com... > hi, > > ok , now found Facturamiszei.PRG : > > 1.) Set( _SET_DEVICE, 'PRINTER' ) > Set( _SET_PRINTFILE, xPrn ) > > hm .. i think this is not enough > > SET CONSOLE OFF > SET PRINTER TO LPT2 > SET PRINT ON > IF Set2FILE() > SET PRINTER TO C:\print\kuplz.prn > ENDIF > > 2.) @ 0,0 Say tINITPRN > > try this > > ?? CHR( 27 ) + CHR( 64 ) > ?? CHR( 27 ) + CHR( 80 ) + CHR( 15 ) > SET DEVICE TO PRINT > > 3.) Set( _SET_DEVICE, 'SCREEN' ) > Set( _SET_PRINTFILE, '' ) > > this is my "out" > > SET CONSOLE OFF > SET PRINT ON > EJECT > ?? CHR( 18 ) > ?? CHR( 27 ) + CHR( 80 ) > ?? CHR( 27 ) + CHR( 64 ) > SET PRINTER TO LPT1 > SET PRINT OFF > IF Set2FILE() > SET PRINTER TO > ENDIF > SET DEVICE TO SCREEN > SET CONSOLE ON > > *** > about : BEGIN SEQUENCE / RECOVER > > after RECOVER 1st you have to "restore" your old Errorblock > > bSaveError := ErrorBlock() > DO WHILE .T. > ErrorBlock( {|e| Break(e)} ) > BEGIN SEQUENCE > ... > EXIT > RECOVER > ErrorBlock( bSaveError ) > ... > LOOP / RETURN .F. / QUIT > END SEQUENCE > ENDDO > ErrorBlock( bSaveError ) > > so you got those recursive Entry in XppFatal.log > > i see no Xbase++ BUG, only not working Code ... > > greetings by OHR > Jimmy > > > > > > | |
Andreas Gehrs-Pahl | Re: extrange behaviour !!! fui testigo on Mon, 10 May 2010 04:18:35 -0400 Jorge, You are mixing two different things here. 1) DbCloseAll() and DbCloseArea() might fail and might cause an error, including IDSC errors. In such a case, the return value of DbCloseAll() and/or DbCloseArea() might be something else but NIL. This is something that Alaska would have to address. I have never bothered to test or use the return value of either of those functions, so I can't tell if they ever returned a value other than NIL. I treat them as Procedures and I can't imagine any circumstances where the return value would matter. 2) Your code is wrong and creates a recursion in your Error Handler, which leads to an XppFatal error log and program termination. As I don't know what causes 1) and how to prevent it from happening in your specific case, there is nothing I (or anybody else here) can help you with, unless you can post a compilable, working, program that shows that problem -- including data files etc. -- and exact instructions on how to re-create the error. But because it is relatively easy to help you with 2) you have gotten a lot of responses about this issue. As you posted the XppFatal.log and some code snippets, everybody assumed you wanted us to help you with the errors in your code, with respect to not setting the ErrorBlock() back right after "RECOVER". If you do this, your program won't create the XppFatal.log and no recursion would occur. Only Alaska can help you with 1) but they also would need a reproducible example. As soon as the Alaska Knowledge Base is up again, you could take a look at all "DbClose" -related PDRs, and if your case isn't covered yet, you could submit a PDR to Alaska. That would be the "official" way to get this problem fixed. Hope that helps, -- Andreas --- --- Andreas Gehrs-Pahl E-Mail: GPahl@CharterMI.net 415 Gute Street or: Andreas@DDPSoftware.com Owosso, MI 48867-4410 or: Andreas_Gehrs-Pahl@CrimeCog.com Tel: (989) 723-9927 Web Site: http://www.Aerospace-History.net --- --- | |
Jorge L | Re: extrange behaviour !!! fui testigo on Mon, 10 May 2010 17:14:20 -0300 Andreas i had never thought that dbcloseall () it would generate a mistake inside my errorsys, then, your conclusion is ok thanks again "Andreas Gehrs-Pahl" escribió en el mensaje de noticias news:2r51n22dnm7r.15imp9sse28p7.dlg@40tude.net... > Jorge, > > You are mixing two different things here. > > 1) DbCloseAll() and DbCloseArea() might fail and might cause an error, > including IDSC errors. In such a case, the return value of DbCloseAll() > and/or DbCloseArea() might be something else but NIL. This is something > that Alaska would have to address. I have never bothered to test or use > the return value of either of those functions, so I can't tell if they > ever returned a value other than NIL. I treat them as Procedures and I > can't imagine any circumstances where the return value would matter. > > 2) Your code is wrong and creates a recursion in your Error Handler, which > leads to an XppFatal error log and program termination. > > As I don't know what causes 1) and how to prevent it from happening in > your specific case, there is nothing I (or anybody else here) can help you > with, unless you can post a compilable, working, program that shows that > problem -- including data files etc. -- and exact instructions on how to > re-create the error. > > But because it is relatively easy to help you with 2) you have gotten a > lot of responses about this issue. As you posted the XppFatal.log and > some code snippets, everybody assumed you wanted us to help you with the > errors in your code, with respect to not setting the ErrorBlock() back > right after "RECOVER". If you do this, your program won't create the > XppFatal.log and no recursion would occur. > > Only Alaska can help you with 1) but they also would need a reproducible > example. As soon as the Alaska Knowledge Base is up again, you could take > a look at all "DbClose" -related PDRs, and if your case isn't covered yet, > you could submit a PDR to Alaska. > > That would be the "official" way to get this problem fixed. > > Hope that helps, > > -- Andreas > > --- --- > Andreas Gehrs-Pahl E-Mail: GPahl@CharterMI.net > 415 Gute Street or: Andreas@DDPSoftware.com > Owosso, MI 48867-4410 or: Andreas_Gehrs-Pahl@CrimeCog.com > Tel: (989) 723-9927 Web Site: http://www.Aerospace-History.net > --- --- > | |
Jorge L | Re: extrange behaviour !!! fui testigo on Sat, 08 May 2010 09:15:07 -0300 Thanks to everything for trying to supportme To try to correct my mistakes is my aim and probably my obsession leads me to seeing things that are not regards "Jorge L" <jlborlando@way.com.ar> escribió en el mensaje de noticias news:1796f9a2$1effb409$5f5fa@news.alaska-software.com... > hello to all > > Hi to all > > when i test my program..... > > i have open a dbf with dbu (compiled with xbase....) in exclusive mode ! > > when my program trie open this dbf in shared mode, when the aperture fail > i run dbcloseall() command to quit to my aplication > and giveit "internal structure corrupted" > all cases that i run again the program with the same situation, work fine > ! > > oError:genCode : 41,00 > oError:operation : DbCloseAll > oError:osCode : 0,00 > oError:severity : 2,00 > oError:subCode : 5,00 > > regards > > |