Hans Martin Kern Posted July 11, 2022 Share Posted July 11, 2022 One of our plug-ins is automagically exporting symbols to a library file using virtual bool VCOM_CALLTYPE ExportResourceN(MCObjectHandle resource, IFileIdentifier* pFileID = nil, TImportResourceConflictCallbackProcPtr conflictCallback = nil) = 0; Works like a charm. Users have requested that we should export the symbol into a resource folder within the library file - so the structure of the library file is somewhat "tidier" and easier to work with when they open it up for maintenance purposes. Is there a way to accomplish that with the SDK? Quote Link to comment
PatW Posted July 11, 2022 Share Posted July 11, 2022 What you could try is to put it temporaly in a folder before exporting and see if ExportResourceN maintaince the structure. Another solution I can think of is opening the lib file and create the folder. Unfortunately this can not be done silently so the user will see the file poping up for a second. if ( gSDK->OpenDocumentPath( fileID, true)) { // DoStuff gSDK->DoMenuName("Save", 0); gSDK->CloseDocument(); gSDK->HandlePendingUpdatesAndActivates(); //workaround for bug in OnFileContent: to trigger closedocument } Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.