As of today several users are reporting issues with connections from our windows application to MYOB.
I believe it is related to the underlying use of Internet Explorer as a part of the embedded web browser in the application. I can also see another client has reported exactly the same issue. As far as I am aware, this issue has only started today. It appears something has changed in the MYOB web pages that IE does not like.
Please see an update on the recent issues that some users of 3rd party apps are experiencing when trying to authenticate to the API.
There are two distinct errors (below):
"Allow Access" page not displaying correctly This is caused by 3rd party apps using unsupported browser versions in their implementations. We have worked to quickly develop and release a patch which should mitigate the issues with the “"Allow Access” button not displaying correctly when authorising a user for an app. This patch will only fix the display issue with the "Allow Access" window and may not fix any issues with redirecting the user back to the app after authentication. These issues are due to an unsupported browser implementation, in which case the developer will need to update their app to support the latest browser version.
App unable to complete the authentication process Some apps are using browser implementations which are no longer supported, impacting the authentication process. The developer will need to update the app to a supported browser version. MYOB recommends using the latest version of your web browser, or at least the previous version.
We apologise for the inconvenience. If you are a developer and require further assistance, please contact API support via the form below:
MikeG1I want to re-iterate that this issue IS NOT caused by 3rd party apps using unsupported browser versions (in many instances, developers may not even be aware of the low level browser implementations used many layers down in their chosen technogy stacks and libraries, or the technologies chosen many years ago by developers no longer on site). It HAS BEEN triggered by MYOB making a change to their AUTH process without any warning or notification.
I can confirm that the credentials page is now rendering correctly, but that the AUTH process no longer works for our application. This means that anyone requiring urgent access to MYOB data at this time will have no success; as others have already pointed out this has impacted the payments to and from potentially 100s of people.
Inconvenience does not come remotely close to describing the situation that MYOB has created. The time required to prepare and release software into financial instiutions for very good reasons is excessive. I know I'd be looking way beyond just changing the integration with MYOB, I'd be looking at moving the integration to NOT-MYOB. Flippant "you fix your software" responses to an issue caused by MYOB are inexcusable. I also note that others are aready raising the question of liability, Trish_LeeKerry_Busby what are your thoughts on this?
Totally agree with your statement. As a developer partner of MYOB for over 20 years, I have never experienced this situation. Previously any changes that would affect 3rd Party apps were communicated to the Developer Partners well in advance so that any required changes could be done. In fact, a beta version was provided in advance of release.
Also, I can confirm that the credentials page is now rendering correctly, but that the AUTH process no longer works for our application.
We were not aware of the low-level browser implementations used many layers down in our chosen Technolgy libraries and unfortunately it is not something that we can fix overnight. We are looking at a minimum of 3 weeks to change, test and deploy to our clients.
The 'not our problem' attitude in the update response is totally irresponsible and bordering on complete arrogance to a group of what are actually also MYOB clients. As clients we also pay quite a substantial fee to MYOB to be part of a program that helps to ensure the MYOB everyday clients remain with MYOB as they are using Add-Ons that not only extend the usability and functionality of the MYOB product, but also tie them to the MYOB product because of the investment in the addon products which may not be available for another accounting software.
I am hoping that come Monday morning, someone at MYOB sees some sense, realises that the impact of this change without notification, has not only affected the addon developers as a group but a massive number of AccountRight online subscription users who use the affected apps and roll back the change to the AUTH process for a period of time to allow developers to adjust the apps and allow the clients to continue to use the system.
Otherwise, we will be looking at informing our clients publicly exactly why their software is no longer compatible with ours.
As a company, we pride ourselves and have an extremely high reputation for our support for our customers, with this issue caused completely by MYOB making a change to their AUTH process without any warning or notification, I have received some of the most abusive phone calls in the entire 26 years of our Company history.
I also am appalled that as of Sunday 18th Aug 2024 at 5pm AEST, after submitting a support request as suggested more than 72 hours ago, that I have had no response.
I would not be in business if it took me that long to respond or even acknowledge a support request.
Hi All, I've been working though this for several days and I've built a test app (i've built this using example code from the community) using the WebView2 package and still no luck.
Even when I try using Edge I still get an error message as below:
Other times I get and IP Address error message.
I'm trying this on my Dev and other device with the same results, the best I've had so far is edge in that it gave me back a code.
I have tried my test app and I've only ever got back a response with the code in it and off course it had an error.
Below is the code for the form as I can't add the project files....
Public Class frmWebView Private Async Sub frmWebView_Load(sender As Object, e As EventArgs) Handles MyBase.Load txtURL.Text = "https://www.google.com.au" LogMsg($"MS Edge Version: {CoreWebView2Environment.GetAvailableBrowserVersionString()}") ' Initialise. Await wvwMain.EnsureCoreWebView2Async() 'Await InitializeCoreWebView2Async(Path.Combine("C:\Temp", Reflection.Assembly.GetExecutingAssembly().GetName().Name))
If Not String.IsNullOrEmpty(txtURL.Text) Then ' Navigate to URL. WebsiteNavigate(txtURL.Text) End If End Sub
Private Sub frmWebView_FormClosed(sender As Object, e As FormClosedEventArgs) Handles MyBase.FormClosed ' Unsubscribe from CoreWebView2 event(s) (remove event handlers). RemoveHandler wvwMain.CoreWebView2.HistoryChanged, AddressOf wvwMain_HistoryChanged End Sub
Private Sub txtURL_KeyPress(sender As Object, e As KeyPressEventArgs) Handles txtURL.KeyPress '// Press ENTER If Asc(e.KeyChar) = 13 Then '// No beep e.Handled = True Try 'wvwMain.CoreWebView2.Navigate(txtURL.Text) '// Or --> wvwMain.CoreWebView2.Navigate(txtURL.Text) wvwMain.Source = New Uri(txtURL.Text) Catch ex As UriFormatException MessageBox.Show("The URL must be fully styled, such as the prefix. http[s]://") Catch ex As Exception MessageBox.Show($"Error: {ex}") End Try End If End Sub
Private Sub wvwMain_CoreWebView2InitializationCompleted(sender As Object, e As CoreWebView2InitializationCompletedEventArgs) Handles wvwMain.CoreWebView2InitializationCompleted LogMsg("wvwMain_CoreWebView2InitializationCompleted") LogMsg($"UserDataFolder: {wvwMain.CoreWebView2.Environment.UserDataFolder.ToString()}") ' Subscribe to CoreWebView2 event(s) (add event handlers). AddHandler wvwMain.CoreWebView2.HistoryChanged, AddressOf wvwMain_HistoryChanged End Sub
Private Sub wvwMain_NavigationCompleted(sender As Object, e As CoreWebView2NavigationCompletedEventArgs) Handles wvwMain.NavigationCompleted MessageBox.Show(wvwMain.Source.ToString()) LogMsg("wvwMain_NavigationCompleted") End Sub
Private Sub wvwMain_WebMessageReceived(sender As Object, e As CoreWebView2WebMessageReceivedEventArgs) Handles wvwMain.WebMessageReceived LogMsg("wvwMain_WebMessageReceived") End Sub
Private Async Function InitializeCoreWebView2Async(Optional userDataFolder As String = "") As Task Dim options As CoreWebView2EnvironmentOptions = Nothing Dim cwv2Environment As CoreWebView2Environment = Nothing
' It's recommended to create the userDataFolder in the same location ' that your other application data is stored (ie: in a folder in %APPDATA%) ' if not specified, we'll create a folder in %TEMP% If String.IsNullOrEmpty(userDataFolder) Then userDataFolder = Path.Combine(Path.GetTempPath(), Reflection.Assembly.GetExecutingAssembly().GetName().Name) End If
' Create WebView2 Environment using the installed or specified WebView2 Runtime version. 'cwv2Environment = Await CoreWebView2Environment.CreateAsync("C:\Program Files (x86)\Microsoft\Edge Dev\Application\1.0.1054.31", userDataFolder, options) cwv2Environment = Await CoreWebView2Environment.CreateAsync(Nothing, userDataFolder, options) ' Initialise. Await wvwMain.EnsureCoreWebView2Async(cwv2Environment) End Function
Private Sub wvwMain_HistoryChanged(sender As Object, e As Object) LogMsg("wvwMain_HistoryChanged") 'btnBack.Enabled = WebView21.CoreWebView2.CanGoBack 'btnForward.Enabled = WebView21.CoreWebView2.CanGoForward ' Update the Address Bar. UpdateAddressBar() End Sub
Private Sub LogMsg(msg As String, Optional addTimestamp As Boolean = True) If addTimestamp Then msg = $"{Now.ToString("yyyy/MM/dd HH:mm:ss.fff")} - {msg}" End If
Debug.WriteLine(msg) End Sub
Private Sub UpdateAddressBar() '' If necessary, update address bar. 'If textBoxAddressBar.Text <> wvwMain.Source.ToString() Then ' textBoxAddressBar.Text = wvwMain.Source.ToString()
' 'move cursor to end of text ' textBoxAddressBar.SelectionStart = textBoxAddressBar.Text.Length ' textBoxAddressBar.SelectionLength = 0 'End If End Sub
Private Sub WebsiteNavigate(ByVal dest As String) If wvwMain IsNot Nothing AndAlso Not String.IsNullOrWhiteSpace(dest) Then ' URL must start with one of the specified strings ' if Not, pre-pend with "https://" If Not dest = "about:blank" AndAlso Not dest.StartsWith("edge://") AndAlso Not dest.StartsWith("file://") AndAlso Not dest.StartsWith("http://") AndAlso Not dest.StartsWith("https://") AndAlso Not System.Text.RegularExpressions.Regex.IsMatch(dest, "^([A-Z]|[a-z]):") Then ' Set Value dest = "https://" & dest End If
' Option 1. 'wvwMain.Source = New Uri(dest, UriKind.Absolute) ' Option 2. wvwMain.CoreWebView2.Navigate(dest) ' Update the Address Bar. UpdateAddressBar() End If End Sub End Class
You seem to be on the right track, but I don't see where you parse "code=..." from the "https://desktop?code=..." URL. It looks like you are treating it like a "normal" URL and opening it in the browser.
The "desktop" URL is what MYOB call the "Redirect URL", which is used to get back to your application after going through the MYOB login screens. When you get the "desktop" URL, instead of browsing to it (which gives the error you posted), you parse the URL to get the "code" value, which is used in subsequent communication with MYOB.
Your screenshot shows the "code" in the redirect URL, Phil_Jeffrey_KC posted an answer that might help you here.