GM_LoadLayerListEx popups and clipboard pollution

oic_chrisoic_chris Global Mapper UserPosts: 15
edited January 2013 in SDK
Aloha!

I have written a chart file scanner application, which would: scan the specified chart repository, load potential charts via GM_LoadLayerListEx, and save the successful charts to a database. This is similar to your Map Catalog, but we needed more functionality, so we implemented our own. We are experiencing some issues with GM_LoadLayerListEx.

Certain chart types (so far *.txt) causes a dialog to popup even with the flags: GM_LoadFlags_HideAllPrompts | GM_LoadFlags_NoProjPrompt | GM_LoadFlags_HideWarnings | GM_LoadFlags_HideUnknownPrompt | GM_LoadFlags_UseDefaultPos, specified. For *.txt files, it pops up the "Generic ASCII Text File Import Options" dialog. I only have a small subset of file types, so there may be others that could popup a dialog. May I suggest, when GM_LoadFlags_HideAllPrompts (or whichever is relevant) is provided, only a message is generated via the function provided to GM_SetMessageCallback()? For our database, if the user wanted to add charts that do not provide enough information, they would need to provide it manually... and somehow provide the data to your Load functions. This manual add functionality is not needed at this time, but may be visited in the future.

There is an issue with error messages, which even though the error handler is provided with GM_SetMessageCallback(), the message is still placed into the clipboard. This is an issue, considering our chart scanner will be running in the background. Perhaps, if the error handler is provided, don't place the error message into the clipboard? Writing this post with the scanner running made it quite difficult to copy-paste code snippets.

Mahalo for your time and awesome work! Keep it up!
Chris

Comments

Sign In or Register to comment.