0

我正在调试一个函数并尝试在 API 调用上设置断点,但我收到了一条“断点当前不会被命中”的消息。这是代码:

bool __stdcall FileOperator::uploadDocument(char* filePath,long projectID)
    {
        char* filename="xyz.xlsx";
        char* docname="xyz.xlsx";
        long docID=0L;
        long lAttributeID=0;
        long lngAppID=aaApi_GetFExtensionApplication(L"xlsx");
        long lngWorkSpaceID=aaApi_GetWorkspaceProfileId(projectID,0);
        WCHAR strWorkingDir[_MAX_PATH];

        memset(strWorkingDir,'\0',_MAX_PATH);

        bool status=aaApi_CreateDocument(
            &docID,
            projectID,
            0,
            0,
            0,
            lngAppID,
            0,
            lngWorkSpaceID,
            convertCharArrayToLPCWSTR(filePath),
        convertCharArrayToLPCWSTR(filename),
        convertCharArrayToLPCWSTR(docname),
            NULL,
            NULL,
            FALSE,
            AADMSDOCCREF_DEFAULT,
            strWorkingDir,
            _MAX_PATH-1,
            &lAttributeID
            );
        return status;    
    }

如果我尝试在aaApi_CreateDocument调用上设置断点,我会收到以下消息:

The breakpoint will not currently be hit.  
No executable code of the debugger's target code type is associated 
with this line.
Possible causes include: conditional compilation, compiler optimizations,
or the target architecture of this line is not supported by the current 
debugger code type.

然后在程序运行时跳过这一行。我怎样才能a)设置断点和b)让该行执行?

4

0 回答 0