We have custom modules built for V8 2004 that we are now porting to V8i. The code works fine in V8 2004, and when recompiled in V8i doesn't report any error, but we've lost some functionality for no readily apparent reason.
Specifically, we have a hook function that is added via
aaApi_AddHook (AAHOOK_CHANGE_DOCUMENT_FILE, AAPREHOOK, HookAddDeleteChangeDocumentFile_Pre)
What is supposed to (used to) happen is that HookAddDeleteChangeDocumentFile_Pre() checks aParam2 for AAOPER_DOC_CHANGE_FILE operation. If that operation occurs (such as renaming a file), it does some other checks, and if they pass, returns AAHOOK_SUCCESS and allows the user action (rename in this example), otherwise, throws an error message and AAHOOK_ERROR returned, preventing the file rename.
In debugging this, it appears that a file rename event handled through the document Properties dialog is no longer hooked to AAHOOK_CHANGE_DOCUMENT_FILE, as was the case in V8 2004. The hook function is never called.
Is there another hook/operation to use instead? Or is this no longer possible in V8i? Thanks.
Thank you Michael and Gray. I was able to create a new hook using the information provided, and now it works perfectly.
Jeff
Please note that I post here on a voluntary basis and am not a Bentley employee.