locked
error C2065: 'RPC_CSTR' : undeclared identifier RRS feed

  • Question

  • I am getting following error , while create dll.

    installer\UUIDGenerator.cpp(35) : error C2065: 'RPC_CSTR' : undeclared identifier
    installer\UUIDGenerator.cpp(35) : error C2059: syntax error : ')'
    installer\UUIDGenerator.cpp(68) : error C2059: syntax error : ')'
    NMAKE : fatal error U1077: 'cl.exe' : return code '0x2'

    Cause :

     UuidToStringA(&uuid, (RPC_CSTR*)&str);

    Please help me to solve this, I already include " <rpc.h> "


    Wednesday, July 16, 2014 12:56 PM

All replies

  • How is RCP_CSTR defined? 
    Thursday, July 17, 2014 1:12 AM
  • RPC_CSTR is defined in the RpcDce.h in PSDK.

    This is rather odd. Can you save preprocessor output for this and check what it you end-up from including rpc.h

    Make sure you do not have some other file named "rpc.h" somewhere in your include path, which prevents correct include from the PSDK.


    Yan

    Thursday, July 17, 2014 7:27 PM
  • Thanks for Your reply, I ensured that there is no any other file named "rpc.h" , 
    Friday, July 18, 2014 7:14 PM
  • Did you save and look at the preprocessor output?

    Yan

    Tuesday, July 22, 2014 12:55 PM