errsysw - division by zero

errsysw - division by zero

Postby Otto » Wed Jun 03, 2009 5:52 pm

Hello Antonio,

Is there a reason why

“by default, division by zero yields zero”
is not included.

Why is the source code errsysw.prg in FWPPC in folder classes?

Thanks in advance
Otto
********************************************************************
mod harbour - Vamos a la conquista de la Web
modharbour.org
https://www.facebook.com/groups/modharbour.club
********************************************************************
User avatar
Otto
 
Posts: 6003
Joined: Fri Oct 07, 2005 7:07 pm

Re: errsysw - division by zero

Postby Antonio Linares » Thu Jun 04, 2009 4:35 am

Otto,

It is included in errsysw.prg:
Code: Select all  Expand view

static function ShowError( oError )

   local cError := oError:Description
   local n
   
   if oError:GenCode == EG_ZERODIV
      return 0
   end

   ...
 

We use just one set of files for both FWH and FWPPC, so in order to have a different errsysw.prg from FWH, we need to place FWPPC one in classes folder.
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 41313
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: errsysw - division by zero

Postby Otto » Thu Jun 04, 2009 6:45 am

Hello Antonio,
thank you. Yes you are right. But I don’t understand why if
tisch->menge is 0 the program freezes:
nPreis := tisch->wert / tisch->menge

I use now this code which works:
if tisch->menge <> 0
nPreis := tisch->wert / tisch->menge
endif

Best regards,
Otto
********************************************************************
mod harbour - Vamos a la conquista de la Web
modharbour.org
https://www.facebook.com/groups/modharbour.club
********************************************************************
User avatar
Otto
 
Posts: 6003
Joined: Fri Oct 07, 2005 7:07 pm


Return to FiveWin for Pocket PC

Who is online

Users browsing this forum: No registered users and 4 guests