SET ALTER TO cFile ?

SET ALTER TO cFile ?

Postby Jimmy » Tue Jul 12, 2022 12:59 am

hi,

for Debug i use

Code: Select all  Expand view
  SET ALTER TO "_LOGIT2.TXT"
   onDummy("Hello World")
   SET ALTER TO
 

and Function
Code: Select all  Expand view
FUNCTION onDummy()
LOCAL iMax   := PCOUNT()
LOCAL i
LOCAL cText  := ""
LOCAL xValue

*   IF lDebug = .T.
      FOR i := 1 TO iMax - 1
         cText += Var2Char( PValue( i ) ) + CHR( 9 )
      NEXT
      cText += Var2Char( PValue( iMax ) )

      SET CONSOLE OFF
      SET ALTER ON

      ? cText

      SET ALTER OFF
      SET CONSOLE ON
*   ENDIF
RETURN NIL

but when call onDummy() under FiveWin i got a
Code: Select all  Expand view
Messagebox(cText, "Alert")

and nothing is redirect to _LOGIT2.TXT :shock:

so how under FiveWin :?:
greeting,
Jimmy
User avatar
Jimmy
 
Posts: 1725
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany

Re: SET ALTER TO cFile ?

Postby hmpaquito » Tue Jul 12, 2022 7:22 am

Hi,

? command is translated to msgbox alert in fivewin.ch

A workaround is change ? command for Qout() function

Regards
hmpaquito
 
Posts: 1482
Joined: Thu Oct 30, 2008 2:37 pm

Re: SET ALTER TO cFile ?

Postby Detlef » Tue Jul 12, 2022 9:31 am

Hi Jimmy,

for debugging or log I use the following:
outside the Main function a static cLog := ""
Then all debug info I append to cLog += 'interesting info' + CRLF.
At the end I call msginfo( cLog ).

May be this could work for you too.
Regards,
Detlef
User avatar
Detlef
 
Posts: 209
Joined: Mon Feb 07, 2022 9:54 pm

Re: SET ALTER TO cFile ?

Postby Otto » Tue Jul 12, 2022 10:20 am

Hello Jimmy,
there is also fwlog function.

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: 6329
Joined: Fri Oct 07, 2005 7:07 pm

Re: SET ALTER TO cFile ?

Postby Jimmy » Tue Jul 12, 2022 7:43 pm

hi,
hmpaquito wrote:? command is translated to msgbox alert in fivewin.ch
A workaround is change ? command for Qout() function

AHA ...
thx for Workaroud
greeting,
Jimmy
User avatar
Jimmy
 
Posts: 1725
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot] and 108 guests