CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3
  1. #1
    Join Date
    Feb 2021
    Posts
    1

    Excel Crash using a new MS Office 365(16.0) ACEDAO.DLL

    A VC++ application using ACEDAO to connect MS Access databases is no longer working post an Office 365 upgrade last year.

    The debug version throw an exception when the inline function _DBEngine::OpenDatabase is called, stating"Run-Time Check Failure #0 - The value of ESP was not properly saved across a function call. This is usually a result of calling a function declared with one calling convention with a function pointer declared with a different calling convention."

    Further check of local variables can see that the DB name parameter is corrupted when the raw_OpenDatabase function is called.

    If this issue is caused by a wrong calling convention, then if there a way to redefine it for functions and variables?

    The application worked on MS Office 365 (16.0) upgrade version 2006 and before.

    Many thanks for your help in advance.

  2. #2
    Join Date
    Mar 2019
    Posts
    2

    Re: Excel Crash using a new MS Office 365(16.0) ACEDAO.DLL

    C ++ projects fail very hard. makes you more persistent.

  3. #3
    2kaud's Avatar
    2kaud is offline Super Moderator Power Poster
    Join Date
    Dec 2012
    Location
    England
    Posts
    7,822

    Re: Excel Crash using a new MS Office 365(16.0) ACEDAO.DLL

    If this issue is caused by a wrong calling convention, then if there a way to redefine it for functions and variables?
    The standard calling convention for c/c++ programs is __cdecl where the stack is cleaned up by the caller. Windows functions often use __stdcall where the stack is cleaned up by the callee (WINAPI is a macro that refers to __stdcall).

    If the __stdcall is needed, then this needs to be specified when the function is declared/defined.
    All advice is offered in good faith only. All my code is tested (unless stated explicitly otherwise) with the latest version of Microsoft Visual Studio (using the supported features of the latest standard) and is offered as examples only - not as production quality. I cannot offer advice regarding any other c/c++ compiler/IDE or incompatibilities with VS. You are ultimately responsible for the effects of your programs and the integrity of the machines they run on. Anything I post, code snippets, advice, etc is licensed as Public Domain https://creativecommons.org/publicdomain/zero/1.0/ and can be used without reference or acknowledgement. Also note that I only provide advice and guidance via the forums - and not via private messages!

    C++23 Compiler: Microsoft VS2022 (17.6.5)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured