From: TW on
Hi,

I'm using VO2.7B. My applications run fine in 32 bits windows but
running in 64 bits windows. It has lots of access violation 5333
errors. By allocated Dynamic memory, some problem can be solved, but
some still unable to solved.

Most of the problem is caused by continuous opening of Data Dialog for
a few times. Then the 5333 error will occur. I tried to use
SetMaxDynSize( 33554432 ) and set DynSize(320). It seems better but it
still happen in a lter stage, I also tried to use CollectForced() and
the program will crash right away.

One strange thing happend in a method EditFocusChange of the
DataDialog..The coding is written as follows :


METHOD EditFocusChange(oEditFocusChangeEvent) CLASS ItemDialog
LOCAL oControl AS Control
LOCAL lGotFocus AS LOGIC
STATIC nPOrder AS FLOAT

oControl := IIf(oEditFocusChangeEvent == NULL_OBJECT, NULL_OBJECT,
oEditFocusChangeEvent:Control)
lGotFocus := IIf(oEditFocusChangeEvent == NULL_OBJECT, FALSE,
oEditFocusChangeEvent:GotFocus)
SUPER:EditFocusChange(oEditFocusChangeEvent)
//Put your changes here
DO CASE
CASE oControl:NameSym == #nOrder
IF lGotFocus
nPOrder := self:oDCnOrder:Value
ELSE
IF Round(nPOrder,2) <> Round(self:oDCnOrder:Value,2)
SELF:CalExtPrice(')
SELF:CalBackOrder()
ENDIF
ENDIF
ENDCASE
RETURN NIL

The 2nd Method CalBackOrder is never performed. It looks like that it
goes to CalExtPrice and then vanish.


If I run the same program in 32 bit windows, it did go thru both
methods.
Does anybody know what's wring ?

Thanks.

Tyrone



From: Stephen Quinn on
Tyrone

> SELF:CalExtPrice(')
So what does CalExtPrice() do with the single quote passed to it??
What happens in CalExtPrice() (show the code) or are we to guess??

> The 2nd Method CalBackOrder is never performed. It looks like that it
> goes to CalExtPrice and then vanish.
Are you sure??
Could CalBackOrder () be failing after CalExtPrice() does it's thing??

> nPOrder := self:oDCnOrder:Value
What's the point of setting this when it'never used after the assignment??

CYA
Steve


From: Massimo Bighelli on

if you have copied/pasted your code there is something strange in
> SELF:CalExtPrice(')
look at the parameter...

Massimo





"TW" <TYRONEWU(a)LIVE.COM> ha scritto nel messaggio
news:0dbeeb55-fdfe-4668-bdde-db0fea5d8ba1(a)b35g2000yqi.googlegroups.com...
> Hi,
>
> I'm using VO2.7B. My applications run fine in 32 bits windows but
> running in 64 bits windows. It has lots of access violation 5333
> errors. By allocated Dynamic memory, some problem can be solved, but
> some still unable to solved.
>
> Most of the problem is caused by continuous opening of Data Dialog for
> a few times. Then the 5333 error will occur. I tried to use
> SetMaxDynSize( 33554432 ) and set DynSize(320). It seems better but it
> still happen in a lter stage, I also tried to use CollectForced() and
> the program will crash right away.
>
> One strange thing happend in a method EditFocusChange of the
> DataDialog..The coding is written as follows :
>
>
> METHOD EditFocusChange(oEditFocusChangeEvent) CLASS ItemDialog
> LOCAL oControl AS Control
> LOCAL lGotFocus AS LOGIC
> STATIC nPOrder AS FLOAT
>
> oControl := IIf(oEditFocusChangeEvent == NULL_OBJECT, NULL_OBJECT,
> oEditFocusChangeEvent:Control)
> lGotFocus := IIf(oEditFocusChangeEvent == NULL_OBJECT, FALSE,
> oEditFocusChangeEvent:GotFocus)
> SUPER:EditFocusChange(oEditFocusChangeEvent)
> //Put your changes here
> DO CASE
> CASE oControl:NameSym == #nOrder
> IF lGotFocus
> nPOrder := self:oDCnOrder:Value
> ELSE
> IF Round(nPOrder,2) <> Round(self:oDCnOrder:Value,2)
> SELF:CalExtPrice(')
> SELF:CalBackOrder()
> ENDIF
> ENDIF
> ENDCASE
> RETURN NIL
>
> The 2nd Method CalBackOrder is never performed. It looks like that it
> goes to CalExtPrice and then vanish.
>
>
> If I run the same program in 32 bit windows, it did go thru both
> methods.
> Does anybody know what's wring ?
>
> Thanks.
>
> Tyrone
>
>
>


--- news://freenews.netfront.net/ - complaints: news(a)netfront.net ---
From: richard.townsendrose on
Tyrone

the stronger the typing and the more that you have error trapping on
the less likely you are to get these. 2830 / 2836 is even better

what are you compiler settings ? thats file, prphject srttings,
compiletime checks - put them ALL ON, and make warnings as errors.

a few libs like reprortpro designer and some of fab's and one of
geoff's libs have the 51422 [number type checking] causing a few
warnings, so accept these [right click in the errors window]. but then
clear these again once you have imported and compiled them.

we have had a 5333 for some years now....

and make sure you diont have any circular realtionships between libns
like lib a depends on lib b depends on lib a etc

richard

richard
From: TW on
Hi,

Sorry. The parameter single quote is a typing mistake. I modified the
routine so that it's easier for other people to understand and not
aware of leaving a single quote there.

I solved the problem by deleted the method CalExtPrice and then
recreate it.
I did not change any coding but I did remove some old comments and it
should not have any affect on it.

I also take Richard's idea to turn on all the compiler checking
options and remove some redundant coding but these coding are also not
relivant to this window.

Without knowing why it works now. May be the key point is to recreate
the CalExtPrice method.

I just don't understand that running on 32 bit windows I have no
problem but in 64 bit windows it give me so much errors.

Anyway. Thanks everyone for their comments and suggestions.

Tyrone