Clipper Code under FiveWin ?

Clipper Code under FiveWin ?

Postby Jimmy » Tue Dec 10, 2019 6:19 am

hi,

i try to compile Clipper Source with FiveWin, is this possible :?:

now it run until @ 8,0 SAY

Code: Select all  Expand view
3972 nMidScreen := 8 + INT( ( ( MAXROW() - 2 ) - 8 ) / 2 )
3973 SETCOLOR( 'w+/b' )
3974 CLEAR SCREEN
3975 DISPBOX( 0, 0, 8, MAXCOL() )
3976 DISPBOX( 8, 0, nMidScreen, MAXCOL() )
3977 DISPBOX( nMidScreen, 0, MAXROW() - 2, MAXCOL() )
3978 @  8,  0               SAY '├'


Application
===========
Path and name: C:\fwh\samples\3\CLICK2.exe (32 bits)
Size: 4,183,552 bytes
Compiler version: Harbour 3.2.0dev (r1904111533)
FiveWin version: FWH 19.06
C compiler version: Borland/Embarcadero C++ 7.0 (32-bit)
Windows version: 6.2, Build 9200

Time from start: 0 hours 4 mins 51 secs
Error occurred at: 12/10/19, 06:58:41
Error description: Error BASE/1004 No exported method: NCLRTEXT
Args:
[ 1] = U

Stack Calls
===========
Called from: => NCLRTEXT( 0 )
Called from: .\source\classes\SAY.PRG => TSAY:NEW( 81 )
Called from: c:\fwh\samples\3\CLICK2.prg => MAIN_SCREEN( 3978 )
Called from: c:\fwh\samples\3\CLICK2.prg => STARTCLICK( 388 )
Called from: c:\fwh\samples\3\CLICK2.prg => MAIN( 137 )
greeting,
Jimmy
User avatar
Jimmy
 
Posts: 1584
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany

Re: Clipper Code under FiveWin ?

Postby Silvio.Falconi » Tue Dec 10, 2019 11:36 am

you cannot use clipper command on fw
Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)
I use : FiveWin for Harbour November 2023 - January 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com
User avatar
Silvio.Falconi
 
Posts: 6768
Joined: Thu Oct 18, 2012 7:17 pm

Re: Clipper Code under FiveWin ?

Postby ukoenig » Tue Dec 10, 2019 1:02 pm

change to :

LOCAL oSay // on top

@ 8, 0 SAY oSay PROMPT '├'

regards
Uwe :D
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany

Re: Clipper Code under FiveWin ?

Postby MOISES » Tue Dec 10, 2019 1:29 pm

Hello,

Use samples/build test.prg to create a DOS .exe app.
Saludos / Regards,

FWH 20.04, Harbour 3.2.0 dev (r1909261630) y BCC 7.40
MOISES
 
Posts: 838
Joined: Wed Aug 22, 2007 10:09 am

Re: Clipper Code under FiveWin ?

Postby Jimmy » Tue Dec 10, 2019 8:40 pm

hi
MOISES wrote:Use samples/build test.prg to create a DOS .exe app.

thx for help but i got a Error when try it
Error: Unresolved external '_HB_FUN_MSGINFO' referenced from C:\FWH\SAMPLES\TEST.OBJ
Error: Unable to perform link
greeting,
Jimmy
User avatar
Jimmy
 
Posts: 1584
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany

Re: Clipper Code under FiveWin ?

Postby Jimmy » Tue Dec 10, 2019 8:41 pm

ukoenig wrote:change to :
LOCAL oSay // on top
@ 8, 0 SAY oSay PROMPT '├'

ooooh ... that will be much work to change all lines ...
is there a Way to use #xtranslate to get that Syntax :?:
greeting,
Jimmy
User avatar
Jimmy
 
Posts: 1584
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany

Re: Clipper Code under FiveWin ?

Postby MOISES » Wed Dec 11, 2019 11:17 am

Please instead of test use your prg
Saludos / Regards,

FWH 20.04, Harbour 3.2.0 dev (r1909261630) y BCC 7.40
MOISES
 
Posts: 838
Joined: Wed Aug 22, 2007 10:09 am

Re: Clipper Code under FiveWin ?

Postby nageswaragunupudi » Wed Dec 11, 2019 1:47 pm

Clipper programs can not be directly compiled and built with FWH directly without any changes. We need to use Windows/Dialogs and use FWH syntax which is similar to clipper syntax but not exactly the same.

Recently we tried in a limited way how far we can make old Clippper syntax work.
Test this example:
Code: Select all  Expand view
#include "fivewin.ch"

function Main()

local n := 200
local c := "Hello    "

 CLEAR

 @  5,  2 SAY 'This is Prompt'
 @  5, 10 GET n
 @  8,  2 SAY "ENTER"
 @  8, 10 GET c

 READ

 ? n, c

return nil
 


Copy to fwh\samples folder and build with buildh.bat

Image
Regards

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

Re: Clipper Code under FiveWin ?

Postby nageswaragunupudi » Wed Dec 11, 2019 3:47 pm

Now, let us try the code posted first:

With minor modifications:

1) Added translate for DISPBOX
2) Changed CLEAR SCREEN as CLEAR //SCREEN .. commented out SCREEN
3) Text of say is made a long text


Code: Select all  Expand view
#include "fivewin.ch"

#xtranslate DISPBOX( <t>,<l>,<b>,<r> ) => TGroup():New( <t>, <l>, <b>, <r>, NIL, nil, nil, nil, nil, nil, nil, .t. )

function Main()

   local nMidScreen

   nMidScreen := 8 + INT( ( ( MAXROW() - 2 ) - 8 ) / 2 )
   SETCOLOR( 'w+/b' )
   CLEAR //SCREEN
   DISPBOX( 0, 0, 8, MAXCOL() )
   DISPBOX( 8, 0, nMidScreen, MAXCOL() )
   DISPBOX( nMidScreen, 0, MAXROW() - 2, MAXCOL() )
   @  8,  0 SAY '+CLIPPER SYNTAX IN FWH'

   READ

return nil
 

Image
Regards

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

Re: Clipper Code under FiveWin ?

Postby Jimmy » Thu Dec 12, 2019 3:06 am

hi,

thx for help.

i agree that Clipper Code is very old but it still work for me with my Xbase++ Code.
i have made a GUI Version in Xbase++ and harbour/HMG but not with FiveWin yet.

i tought Fivewin can use Clipper Code as "Console" that why i try it and got that Message.
i will learn how GUI under FiveWin work. it use OOP which i also use in Xbase++.
greeting,
Jimmy
User avatar
Jimmy
 
Posts: 1584
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany

Re: Clipper Code under FiveWin ?

Postby Jimmy » Thu Dec 12, 2019 3:10 am

hi,
MOISES wrote:Please instead of test use your prg

i will do it when i finish FiveWin Version.
GUI Part now is for harbour / HMG so it will not work under FiveWin and Console Mode was just a try
greeting,
Jimmy
User avatar
Jimmy
 
Posts: 1584
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany

Re: Clipper Code under FiveWin ?

Postby hua » Thu Dec 12, 2019 10:14 am

Jimmy wrote:
i agree that Clipper Code is very old but it still work for me with my Xbase++ Code.
i have made a GUI Version in Xbase++ and harbour/HMG but not with FiveWin yet.

i tought Fivewin can use Clipper Code as "Console" that why i try it and got that Message.
i will learn how GUI under FiveWin work. it use OOP which i also use in Xbase++.


If you want to build console program, you just need to compile and link with [x]Harbour. You link in FWH only if you want windows GUI.
Try googling GTWVT or GTWVG for more info. I didn't experiment much with windows console program
FWH 11.08/FWH 19.12
BCC5.82/BCC7.3
xHarbour/Harbour
hua
 
Posts: 1038
Joined: Fri Oct 28, 2005 2:27 am

Re: Clipper Code under FiveWin ?

Postby Jimmy » Thu Dec 12, 2019 5:36 pm

hi,
hua wrote:If you want to build console program, you just need to compile and link with [x]Harbour. You link in FWH only if you want windows GUI.
Try googling GTWVT or GTWVG for more info. I didn't experiment much with windows console program

thx for Answer.

my working harbour HMG Version is using GTWVT but it is "so slow" ... so i wanted to try other Console
i know GTWVG from Pritpal Bedi while it have same Syntax like Xbase++ but i never have made a GUI Version of CLICK with Xbase++.

---

that Clipper Soure was just a Test.
i have not used Console since Years but someone in HMG Forum ask for "Formatter for Clipper" so i try to rebuild my CLICK Source under harbour / HMG. it run but "Output" under harbour /HMG make App extrem slow. :shock:

without "Output" it use < 4 Seconds but with "Output" it take Minutes :!:
greeting,
Jimmy
User avatar
Jimmy
 
Posts: 1584
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany

Re: Clipper Code under FiveWin ?

Postby Antonio Linares » Fri Dec 20, 2019 9:06 am

Dear Jimmy,

Could you please post some screenshots of your app using GTWVT ?

Does it look nice ? Is the output speed the only problem ?

many thanks
regards, saludos

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

Re: Clipper Code under FiveWin ?

Postby Jimmy » Fri Dec 20, 2019 9:20 pm

hi Antonio,
Antonio Linares wrote:Could you please post some screenshots of your app using GTWVT ?
Does it look nice ? Is the output speed the only problem ?

i have not made a Snapshot from GTWVT Version but it look exact like my Xbase++ Console
Image

i have to say that every "Output" is slow. GTWVT is not slower than Xbase++ Console.

GTWVT "Event-Loop" is just INKEY() and with HMG i can use GUI too e.g. Button.
this is what i don't know with FiveWin while GUI Parts seems all Inherit from TWindows.

HMG use Procedure and Function with #xCommand Syntax so i had to "go back" to Cl*pper Style using Macro.
FiveWin use OOP which make it more easy for me while i have work last 15 Year with that Style.

as i can say GTWVT is a good Console Solution but i can't say if Events will work well with OOP Style.
greeting,
Jimmy
User avatar
Jimmy
 
Posts: 1584
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 47 guests