FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour Wine under Mac with FWH app
Posts: 990
Joined: Thu Nov 17, 2005 05:49 PM
Wine under Mac with FWH app
Posted: Fri May 13, 2022 03:28 PM
Hello everyone;

Wine --https://www.winehq.org-- allows you to run windows applications on Unix like OS like Linux, BSD and Mac.

I'm testing Wine for Mac to run my Windows applications. I'm using a specific implementation called "CrossOver". My FWH application launches perfectly and dialogs and FastReports are shown as expected. However, when opening a window that contains a TExplorerBar I get a runtime error:

Structured Systems Corp Error Sys
-----------------------------------------
c:\PMSys\PMSys.exe
Version Info :Build #1562 Built on: 04.11.2022 @ 15:58:45
Size :5,871,616 bytes
Maximum files : 0
Time since start:0 hours 11 mins 44 secs
Date and Time :05/13/2022, 11:00:18
Network :IMAC
OS User : crossover
ADS DD User :rcb

Details
----------
Error BASE/1004 No exported method: NTOP
Parameter :
[ 1] = U

Stack List
----------
Called from:NTOP(0)
Called from:TEXPLORERBAR:CHECKSCROLL(153)
Called from:TEXPLORERBAR:RESIZE(250)
Called from:HANDLEEVENT(0)
Called from:TEXPLORERBAR:HANDLEEVENT(1731)
Called from:_FWH(3325)
Called from:SETSCROLLRANGE(0)
Called from:(b)TSCROLLBAR(88)
Called from:TSCROLLBAR:SETRANGE(0)
Called from:TSCROLLBAR:WINNEW(198)
Called from:TEXPLORERBAR:NEW(97)
Called from:TCONTRACTORSTBLBRW:VTASKBARMENU(172)
Called from:(b)TTABLEBROWSER_DEFINEDLG(173)
Called from:INITIATE(714)
Called from:ACTIVATE(331)
Called from:TCONTRACTORSTBLBRW:DEFINEDLG(173)
Called from:(b)TTABLEBROWSER_SHOW(183)
Called from:ACTIVATE(1022)
Called from:TMDICHILD:ACTIVATE(262)
Called from:TCONTRACTORSTBLBRW:SHOW(183)
Called from:CONTRACTORSMAINTENANCE(640)
Called from:(b)PMSYS_FRAMEBAR(759)
Called from:CLICK(683)
Called from:LBUTTONUP(919)
Called from:HANDLEEVENT(1721)
Called from:HANDLEEVENT(1866)
Called from:_FWH(3325)
Called from:WINRUN(0)
Called from:TMDIFRAME:ACTIVATE(1036)
Called from:ACTIVATE(243)
Called from:MAIN(53)
CPU type: VirtualApple @ 2.50GHz 2400 Mhz


The error cannot be reproduced under Windows. it only happens under Wine. Any ideas?

Thank you.


Reinaldo.
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: Wine under Mac with FWH app
Posted: Fri May 13, 2022 04:36 PM

Dear Reinaldo,

Not sure what FWH version you are using, as current TExplorerBar has different lines than yours.

Anyhow, the error that you get comes from TEXPLORERBAR:CHECKSCROLL() and the only place where nTop is used is here:

oLastItem = ATail( ::aPanels )
... oLastItem:nTop

so it seems as oLastItem is nil. If you could post a screenshot of your explorerBar then it may be easier to spot why oLastItem is coming as nil.

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 4840
Joined: Fri Nov 18, 2005 04:52 PM
Re: Wine under Mac with FWH app
Posted: Fri May 13, 2022 04:45 PM
Hmm, the error says:

Error BASE/1004 No exported method: NTOP

Apparently, it is trying to call the nTop method which doesn't exist--at least in my old version from 7/2018.
FWH 18.05/xHarbour 1.2.3/BCC7/Windows 10
Posts: 990
Joined: Thu Nov 17, 2005 05:49 PM
Re: Wine under Mac with FWH app
Posted: Fri May 13, 2022 07:20 PM

Right, the error does come from Texplorerbar class and yes, the line being quoted on the error log is addressing the nTop property of an TPanel object. BUT, the code executes perfectly under windows and therefore I was hoping not having to touch method CheckScroll() on the TExplorerBar class. Being that the app executes just fine under windows, I was hoping someone here had seen this before and would recommend some special wine bottle configuration.

So, I went back and made some changes to TexplBar.prg and things are now working just fine.

BTW -- I'm impressed with how well this native windows app executes with wine on a Mac. It is using very many 3rd party APIS such as Zillow api, Advantage database API, Twain, SSL, Topaz, FastReports... and now i get to run it on my M1 Mac with MacOS Monterey version 12.2.1. I remind you that not even virtual box with any version of windows currently runs under the M1 chip. With Wine it works flawlessly (so far).

Thank you,

Reinaldo.

Posts: 1515
Joined: Thu Oct 30, 2008 02:37 PM
Re: Wine under Mac with FWH app
Posted: Fri May 13, 2022 07:33 PM
James Bott wrote:Hmm, the error says:

Error BASE/1004 No exported method: NTOP

Apparently, it is trying to call the nTop method which doesn't exist--at least in my old version from 7/2018.


That Is derived data from TControl class
Posts: 6755
Joined: Wed Feb 15, 2012 08:25 PM
Re: Wine under Mac with FWH app
Posted: Sat May 14, 2022 01:07 AM

Dear Reinaldo
If you use a Dialog as a container for the TExplorerBar and not a window, I advise you to create the controls, including the TExplorerBar, in a separate function that you will call from the bInit of the Dialog. You will tell me

Estimado Reinaldo
Si usas como contenedor del TExplorerBar un Dialog y no una ventana, te aconsejo que la creación de los controles, incluído el TExplorerBar lo hagas en una function aparte que llamarás desde el bInit del Dialog. Ya me contarás

Cristobal Navarro

Hay dos tipos de personas: las que te hacen perder el tiempo y las que te hacen perder la noción del tiempo

El secreto de la felicidad no está en hacer lo que te gusta, sino en que te guste lo que haces
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: Wine under Mac with FWH app
Posted: Sat May 14, 2022 05:41 AM

Dear Reinaldo,

Finally let me remind you that you can use FiveMac to build a true Apple app, without the need for wine, etc

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 3022
Joined: Fri Oct 07, 2005 01:45 PM
Re: Wine under Mac with FWH app
Posted: Mon May 16, 2022 05:46 PM

Antonio,

Please remember that FiveMac does not support some essential Windows functions, because MacOS does not have them. It also does not support ADS.

Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit

Continue the discussion