Abnormal program termination

Abnormal program termination

Postby byte-one » Mon Jan 11, 2016 9:20 pm

Antonio?
The error is present only when using Msgrun(...) in the bAction from the timer!
This test can you show the problem! Please type in get any character and wait for reaction.
Antonio, in some rare cases the program terminates not but in the get suddenly comes chinese letters!
(Unicode?)
Code: Select all  Expand view
function abnormal(oWnd)
local oDlg, oTimer , oSay , cSay := " " , oGet , cGet := space(10) , cBuffer
    DEFINE TIMER oTimer INTERVAL 1000 OF oWnd
    DEFINE DIALOG oDlg OF oWnd FONT oFont_normal
    @ 1, 2 GET oGet VAR cGet
        oGet:bPostKey := {|x,buffer|if(empty(buffer),NIL,;
        (oTimer:bAction:={||NIL},;
        cBuffer := buffer,;
        oTimer:bAction:={||msgrun("Test","Test",{||(cSay := cBuffer, oSay:refresh(),oTimer:deactivate())})},;
        oTimer:activate()))}
        @ 2, 2 SAY oSay PROMPT cSay SIZE 50,15
    @ 3,2 SBUTTON PROMPT "&End" OF oDlg SIZE 50,15 ACTION oDlg:End()
    ACTIVATE DIALOG oDlg CENTERED
return nil
 
I have tested on WIN 10 and XP!
Regards,
Günther
---------------------------------
office@byte-one.com
User avatar
byte-one
 
Posts: 1048
Joined: Mon Oct 24, 2005 9:54 am
Location: Austria

Re: Abnormal program termination

Postby byte-one » Tue Jan 12, 2016 3:07 pm

Antonio, i found the following:
If at begin of the app FW_SetUnicode( .T. ), then the error goes away! In the source of msgrun() you are switch to FW_SetUnicode( .T. ) and return to the old status. This could be the reason!???
Regards,
Günther
---------------------------------
office@byte-one.com
User avatar
byte-one
 
Posts: 1048
Joined: Mon Oct 24, 2005 9:54 am
Location: Austria

Re: Abnormal program termination

Postby Antonio Linares » Wed Jan 13, 2016 11:41 am

Günther,

Yes, it could be related.

In FWH we have done a tremendous work to support unicode and non unicode at the same time. Tipically an app is unicode or it is not.

A FWH app can be unicode and non unicode at the same time, thats why I think it may be related.
regards, saludos

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

Re: Abnormal program termination

Postby byte-one » Wed Jan 13, 2016 12:26 pm

Antonio, for now i link a msgrun.prg in with commented calls to FW_setunicode().
Regards,
Günther
---------------------------------
office@byte-one.com
User avatar
byte-one
 
Posts: 1048
Joined: Mon Oct 24, 2005 9:54 am
Location: Austria

Re: Abnormal program termination

Postby nageswaragunupudi » Sun Jan 17, 2016 8:56 pm

Thanks.
We commented out too from the next release.
Switching of Unicode setting during runtime is not yet supported though we originally wanted to.
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10620
Joined: Sun Nov 19, 2006 5:22 am
Location: India


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 103 guests