View Issue Details

IDProjectCategoryView StatusLast Update
0005782MMW WishlistReports/Scriptspublic2013-07-28 14:06
Reporterzvezdan Assigned To 
PrioritynoneSeverityfeatureReproducibilityalways
Status newResolutionduplicate 
Summary0005782: OpenSQL & CreateFolder errors are not handled with On Error Resume Next
DescriptionI am (we are) getting those ugly error messages saying that SQL has some error, even if I put On Error Resume Next in the front of the OpenSQL. For example:
On Error Resume Next
Set oSongIter = SDB.Database.OpenSQL("SELECT FROM")

If I remove On Error Resume Next I am getting one more error message displayed for each error.

Here is one more example of some API method which cannot be handled:
On Error Resume Next
SDB.Tools.FileSystem.CreateFolder "C:\Temp\P5 ...\Test\"

The possible solution would be to instruct MM by script how to handle given errors. I.e. some properties like DoOnSQLError = seCancel and DoOnFileSysError = ...

One more thing which is not currently handled with scripts is dialog box for moving of accompanying files after oSongData.Path = "..." Until 1250 it was displayed after each emptied folder, and if you have bunch of files from several folders (i.e. if oSongData.Path = ... is inside of some loop) you would get same dialog box several times which could be really tedious. This dialog box is removed from 1251 onward, so all accompanying files (jpg, ...) stay in same old folders even if all audio files are moved to another folder. So, maybe you should return back that dialog box with added some new property like MoveAllAccompanyingFiles = seYes / seNo. I am not sure if it is possible, but even better solution would be to instruct MM to display that dialog box only after some command, something like BeginTransaction and Commit with database commands. So, if I have oSongData.Path inside of some loop, I could put BeginMoveAccompanyingFiles (or similar) in the front of that loop and EndMoveAccompanyingFiles after it and MM would display only one dialog box displaying all accompanying files which could be moved.
Additional Informationhttp://www.mediamonkey.com/forum/viewtopic.php?f=6&t=40369
TagsNo tags attached.

Relationships

duplicate of 0006709 feedbackLudek MMW v4 OpenSQL & CreateFolder errors are not handled with On Error 

Activities

zvezdan

2013-07-28 14:06

updater   ~0037016

This issue is duplicate and should be closed, but I don't have enabled option to do that.