Page 1 of 2
TWebView() and Google Group Account
Posted: Tue Jun 28, 2022 9:50 pm
by Jimmy
hi,
i try Sample c:\fwh\samples\webview.exe and want to use my Google Account but fail
Anmeldung nicht möglich
Dieser Browser oder diese App ist unter Umständen nicht sicher.
Verwenden Sie einen anderen Browser. Wenn Sie bereits einen unterstützten Browser nutzen, können Sie noch einmal versuchen, sich anzumelden.
Sign-in not possible
This browser or app may not be secure.
Use a different browser. If you're already using a supported browser, you can try signing in again.
what can i do

need help please
Re: TWebView() and Google Group Account
Posted: Wed Jun 29, 2022 8:21 pm
by Antonio Linares
Re: TWebView() and Google Group Account
Posted: Wed Jun 29, 2022 8:21 pm
by Jimmy
Re: TWebView() and Google Group Account
Posted: Wed Jun 29, 2022 8:47 pm
by Jimmy
hi Antonio,
thx for Answer.
i have found similar at Github and have read about Google oAuth
i saw Comment to add
after URL but how to do it with CLASS TWebView
Code: Select all | Expand
METHOD Navigate( cURL ) INLINE WebView_Navigate( ::hWebView, cURL )
p.s. when modify FiveWin Source how to rebuild LIB (BCC 7 fiveh.lib, fivehc.lib )
Re: TWebView() and Google Group Account
Posted: Thu Jun 30, 2022 3:03 pm
by Antonio Linares
Dear Jimmy,
Have you tried to run this, after you go to
https://accounts.google.com/o/oauth2/v2/auth ?
oWebView:Eval( "disallow_webview=true;" )
Anyhow, I have just set an issue in the github webview repo asking for it and lets see what they say:
https://github.com/webview/webview/issues/791
Re: TWebView() and Google Group Account
Posted: Thu Jun 30, 2022 3:07 pm
by Antonio Linares
Dear Jimmy,
> p.s. when modify FiveWin Source how to rebuild LIB (BCC 7 fiveh.lib, fivehc.lib )
Once you modify the source and compile generating the OBJ simply do this:
c:\bcc7\bin\TLib Fiveh.lib -+$module.obj /0 /P128
same applies for fivehc.lib
Re: TWebView() and Google Group Account
Posted: Thu Jun 30, 2022 8:04 pm
by Antonio Linares
Dear Jimmy,
Steffen from webview answered this:
Sorry, I am having a hard time seeing how this is related to this webview library. If you could please explain then that would be helpful. Thank you!
Good question. What to tell him ?

Re: TWebView() and Google Group Account
Posted: Thu Jun 30, 2022 11:13 pm
by Jimmy
hi Antonio,
Sample Webview start with Google Website
Code: Select all | Expand
local oWebView := TWebView():New()
oWebView:Eval( "disallow_webview=true;" )
oWebView:Navigate( "http://www.google.com" )
oWebView:Eval( "disallow_webview=true;" )
i upper right of Google Website i try login with UserName and than still got Error Message.
as i understand Google Website can not "identify" which Browser is used
---
Question : can i use TWebview() in "IE compatible" Modus
if Yes, how

Re: TWebView() and Google Group Account
Posted: Fri Jul 01, 2022 5:06 am
by Antonio Linares
Re: TWebView() and Google Group Account
Posted: Fri Jul 01, 2022 5:17 am
by Antonio Linares
Dear Jimmy,
> Question : can i use TWebview() in "IE compatible" Modus

I have no idea about this, sorry

Re: TWebView() and Google Group Account
Posted: Fri Jul 01, 2022 7:57 am
by Antonio Linares
Dear Jimmy,
New answer from Steffen and then he closed the issue:
Thank you.
From my understanding, disallow_webview=true was at the time just way for developers to test whether their apps would be impacted by Google blocking embedded webviews in their OAuth 2.0 authorization flows before making the block effective for everyone.
You can add a query parameter to your authorization request URI to test for potential impact to your application before September 30, 2021
If the question is about how to add that query parameter anyway then I think you need to dive into Google's documentation and get a better understanding of their OAuth 2.0 authorization flow. I do however not think that this applies anymore.
To me it seems like this is on Google for dictating what type of browser is permitted in their authorization flow, and I think that every solution is going to be a workaround.
Should you find that there is a specific technical limitation in this webview library or how it integrates with the underlying browser engines (not only MS WebView2) then I suggest making a new, more specific issue with those details.
I will close this issue as I do not see any way to move forward
If you could explain, step by step, how to reproduce it here maybe we can think about a solution. Please post an animated gif or several screenshots.
many thanks
Re: TWebView() and Google Group Account
Posted: Fri Jul 01, 2022 3:35 pm
by Jimmy
hi Antonio,
i try to login at Google Website with upper right Button ( use Fullscreen of Browser if you don´t see it )

i need Google Account e.g. for "harbour Group" in Google.
---
i have the "feeling" that Google can not "identify Browser", that´s why i ask for "IE-Compatible" Modus
Re: TWebView() and Google Group Account
Posted: Fri Jul 01, 2022 9:55 pm
by Antonio Linares
Dear Jimmy,
It seems as there is an "easy" solution:
https://github.com/MicrosoftEdge/WebView2Feedback/issues/1647You are all geniuses,Settings.UserAgent = "Chrome" Settings.UserAgent = "Android" ,It's working
Now we need to follow this guide to change the UserAgent:
https://www.searchenginejournal.com/change-user-agent/368448/I am trying it right now...

Re: TWebView() and Google Group Account
Posted: Fri Jul 01, 2022 10:16 pm
by Antonio Linares
Got it !!!

I am posting the screenshots...

Re: TWebView() and Google Group Account
Posted: Fri Jul 01, 2022 10:24 pm
by Antonio Linares
I just explained this to Steffen asking him for a way to do it programmatically:
https://github.com/webview/webview/issues/792Lets see what he says...
