I am converting a desktop app to web and trialing mbs libxl to edit and amend templated excel workbooks which are then downloaded. All working fine to a degree, all use a similar method to download the file. Two out of three work perfectly, the third always throws up a spurious dialog box whick I have to ‘Okay’. This is then followed by another dialog box which I have to tick to ‘prevent page creating further dialog boxes etc.’ and then the workbook downloads. I have attached a short video (webm format) to show what I mean.
I cannot see what is throwing up the box, there appears to be nothing in the debugger to ‘catch’ or show where it has come from. All three ‘download’ methods are the same (different webfile properties on the page for each excel file - not that this is required), but the one causing these extra popups is below. I makes no difference if its the first, or 3rd file opened always the same. After the ‘prevent further popups is ticked’ later downloads work fine. I have tried different browsers with same result, I am using Firefox predominantly.
Category is fine
Export is fine
Annual is the problem
if book.Save(file) then
//not sure if this mime type required but seems reasonable
annual.MimeType = "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"
annual.ForceDownload = True
annual = WebFile.Open(file)
ShowURL(annual.URL)
'tempfile.delete
else
MsgBox "Failed to create file."+EndOfLine+EndOfLine+book.ErrorMessage
end if