Thread: c with c++ ??

  1. #1
    Registered User
    Join Date
    Feb 2011
    Posts
    96

    c with c++ ??

    Hi:

    I'm trying to use a c++ function from within c.
    The function is a Windows function:
    GetLastError function (Windows)

    My program is in c.
    I'm getting a 0 as a response to a win.spooler.api function indicating that it fails. I need to know why it's failing.

    So, can I use the GetLastError function from within a c app?

  2. #2
    Registered User
    Join Date
    Jun 2015
    Posts
    1,640
    It's not a C++ function. What makes you think it is?
    More correctly, any C function is pretty much also a C++ function, but not necesssarily vice versa.
    Take a look at my answer to your other question.
    Last edited by algorism; 06-10-2016 at 10:03 AM.

Popular pages Recent additions subscribe to a feed

Tags for this Thread