WebView2 sample

WebView2 sample

Postby Detlef » Sun Jan 28, 2024 5:25 pm

Dear Antonio,

I want to start a new thread about this topic because the old one is getting confusing.

I do not succeed trying to create the sample program 'webview.prg' which I found in FWH 22.10.
The linking process terminates with following messages:
Code: Select all  Expand view  RUN
Turbo Incremental Link 6.70 Copyright (c) 1997-2014 Embarcadero Technologies, Inc.
Error: Unresolved external '_HB_FUN_WEBVIEW_CREATE' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_NAVIGATE' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_SETHTML' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_RUN' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_EVAL' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_INIT' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_GETWINDOW' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_UNBIND' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_SETTITLE' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_SETSIZE' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_SETUSERAGENT' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_TERMINATE' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WV_SENDTOFWH' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_BIND' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_DESTROY' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ

Is this because of my FHW version or am I doing something wrong?
Kind regards,
Detlef
User avatar
Detlef
 
Posts: 209
Joined: Mon Feb 07, 2022 9:54 pm

Re: WebView2 sample

Postby Silvio.Falconi » Sun Jan 28, 2024 5:56 pm

Detlef wrote:Dear Antonio,

I want to start a new thread about this topic because the old one is getting confusing.

I do not succeed trying to create the sample program 'webview.prg' which I found in FWH 22.10.
The linking process terminates with following messages:
Code: Select all  Expand view  RUN
Turbo Incremental Link 6.70 Copyright (c) 1997-2014 Embarcadero Technologies, Inc.
Error: Unresolved external '_HB_FUN_WEBVIEW_CREATE' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_NAVIGATE' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_SETHTML' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_RUN' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_EVAL' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_INIT' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_GETWINDOW' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_UNBIND' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_SETTITLE' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_SETSIZE' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_SETUSERAGENT' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_TERMINATE' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WV_SENDTOFWH' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_BIND' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ
Error: Unresolved external '_HB_FUN_WEBVIEW_DESTROY' referenced from C:\ENTW\FWH22\SAMPLES\TWEBVIEW.OBJ

Is this because of my FHW version or am I doing something wrong?
Kind regards,
Detlef


install https://developer.microsoft.com/en-us/m ... /webview2/ x86 version before using it
then U ust have WebView2Loader.dll and webview.dll in your folder
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: 7070
Joined: Thu Oct 18, 2012 7:17 pm

Re: WebView2 sample

Postby Detlef » Sun Jan 28, 2024 6:38 pm

Silvio.Falconi wrote:install https://developer.microsoft.com/en-us/m ... /webview2/ x86 version before using it
then U ust have WebView2Loader.dll and webview.dll in your folder


Thanks, Silvio.
I already did this but the errors do remain.
User avatar
Detlef
 
Posts: 209
Joined: Mon Feb 07, 2022 9:54 pm

Re: WebView2 sample

Postby Otto » Sun Jan 28, 2024 7:46 pm

I believe I remember that WebView2 has only been included in the FiveWin version since May 2023.
********************************************************************
mod harbour - Vamos a la conquista de la Web
modharbour.org
https://www.facebook.com/groups/modharbour.club
********************************************************************
User avatar
Otto
 
Posts: 6338
Joined: Fri Oct 07, 2005 7:07 pm

Re: WebView2 sample

Postby Silvio.Falconi » Sun Jan 28, 2024 8:54 pm

:lol:
Otto wrote:I believe I remember that WebView2 has only been included in the FiveWin version since May 2023.


I have last release and not run webview
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: 7070
Joined: Thu Oct 18, 2012 7:17 pm

Re: WebView2 sample

Postby Otto » Sun Jan 28, 2024 11:22 pm

Detlef,

All that is missing, as shown in your screenshot, is in the CLASS TWebView (c:\fwh2023\source\classes\twebview.prg).
Perhaps you could try manually linking the class for a test.

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

Re: WebView2 sample

Postby Antonio Linares » Mon Jan 29, 2024 5:56 am

Silvio,

> I have last release and not run webview

What Windows version are you using ?

It works great on Windows 11
regards, saludos

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

Re: WebView2 sample

Postby Otto » Mon Jan 29, 2024 7:05 am

Dear Antonio,
but I believe that Detlef's error cannot be related to the Windows version. I think something is missing in the FiveWin link script here.
He is getting the error during compilation.
For me, the WEBVIEW also works with Windows Server 2012 - I think it corresponds to Windows 10.

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

Re: WebView2 sample

Postby Antonio Linares » Mon Jan 29, 2024 7:46 am

Dear Otto,

I was answering to Silvio's comment:
I have last release and not run webview

> WEBVIEW also works with Windows Server 2012

thanks for the feedback

Dear Detlef,

Could you please check if you have the file FWH\source\classes\twebview.prg ?

thanks
regards, saludos

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

Re: WebView2 sample

Postby Detlef » Mon Jan 29, 2024 8:44 am

Dear Antonio,

yes, I have the file tWebView.prg in source\classes.
And I put this into samples\webview.prg to compile and link.
But it doesn't work.

This is the message if I try to compile tWebView.prg to tWebView.obj:
Code: Select all  Expand view  RUN
Error E2451 twebview.c 71: Undefined symbol 'ModuleFakeDyn'
Error E2141 twebview.c 71: Declaration syntax error
Error E2190 twebview.c 71: Unexpected }
Error E2040 twebview.c 71: Declaration terminated incorrectly
Error E2219 twebview.c 131: Wrong number of arguments in call of macro 'HB_INIT_SYMBOLS_EX_END'
Error E2451 twebview.c 134: Undefined symbol 'hb_vm_SymbolInit_TWEBVIEW'

Thanks for jumping in.
User avatar
Detlef
 
Posts: 209
Joined: Mon Feb 07, 2022 9:54 pm

Re: WebView2 sample

Postby Silvio.Falconi » Mon Jan 29, 2024 10:31 am

Antonio Linares wrote:Silvio,

> I have last release and not run webview

What Windows version are you using ?

It works great on Windows 11


I tried it on Windows Seven and Windows 10 Pro


Code: Select all  Expand view  RUN

Edizione    Windows 10 Pro
Versione    22H2
Data installazione: ‎28/‎04/‎2022
Build sistema operativo 19045.3930
Esperienza  Windows Feature Experience Pack 1000.19053.1000.0
 
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: 7070
Joined: Thu Oct 18, 2012 7:17 pm

Re: WebView2 sample

Postby Silvio.Falconi » Mon Jan 29, 2024 10:38 am

I tried with another computer with windows 10
and seem to run ok
Image

but there is an error on source because not run ok error on Login( cJson, cCalls, oWebView )



Image


but before I get into webview I have to solve the countless problems I have with my desktop applications
always if someone can help me solve them
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: 7070
Joined: Thu Oct 18, 2012 7:17 pm

Re: WebView2 sample

Postby Detlef » Mon Jan 29, 2024 11:55 am

I could avoid the error about "ModuleFakeDyn" by setting the right include path.
But I'm not able to link the tWebView.obj into my exe.

I'm sure doing something wrong when adding the obj file into the linking section of buildx.bat
User avatar
Detlef
 
Posts: 209
Joined: Mon Feb 07, 2022 9:54 pm

Re: WebView2 sample

Postby Otto » Mon Jan 29, 2024 12:06 pm

Detlef, can't you delete the obj in your script and link the prg?
LG
Otto
********************************************************************
mod harbour - Vamos a la conquista de la Web
modharbour.org
https://www.facebook.com/groups/modharbour.club
********************************************************************
User avatar
Otto
 
Posts: 6338
Joined: Fri Oct 07, 2005 7:07 pm

Re: WebView2 sample

Postby Antonio Linares » Mon Jan 29, 2024 12:08 pm

Dear Detlef,

Please use the FWH libs that I just sent you by email and let me know your results

thanks
regards, saludos

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

Next

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 55 guests