SetDefaultPrinter in WinSpool.h
-
hi, I am working on an application to control the printers. I m getting a problem when i use SetDefaultPrinter in VC it gives me error of undeclared identifier i have included the header files. other function related to printers like OpenPrinter, GetPrinter etc r working fine but this one is not working can anybody help me out plzzz its urgent:(. take care contact me at Jaffer_mumtaz@yahoo.com
-
hi, I am working on an application to control the printers. I m getting a problem when i use SetDefaultPrinter in VC it gives me error of undeclared identifier i have included the header files. other function related to printers like OpenPrinter, GetPrinter etc r working fine but this one is not working can anybody help me out plzzz its urgent:(. take care contact me at Jaffer_mumtaz@yahoo.com
It's a new functions only available on NT machines. In order for the compiler to see the function, you have to define WINVER to 0x500. Joel Lucsy
-
It's a new functions only available on NT machines. In order for the compiler to see the function, you have to define WINVER to 0x500. Joel Lucsy
Hi Joel Thnx for replying early. I m working on windows 2000 plzz can u guide me a little more on it.I desperately need the function to work on my machine. what i need to do in the code inorder to use that code. take care
-
Hi Joel Thnx for replying early. I m working on windows 2000 plzz can u guide me a little more on it.I desperately need the function to work on my machine. what i need to do in the code inorder to use that code. take care
You have to include < winspool.h > in the cpp-file where you use it, you have to link against winspool.lib, and you have to read MSDN! Its all in there!
My opinions may have changed, but not the fact that I am right.
-
Hi Joel Thnx for replying early. I m working on windows 2000 plzz can u guide me a little more on it.I desperately need the function to work on my machine. what i need to do in the code inorder to use that code. take care
put the line: #define WINVER 0x0500 in you stdafx.h before any #include's Joel Lucsy
-
put the line: #define WINVER 0x0500 in you stdafx.h before any #include's Joel Lucsy
Hi joel I still get the same error undeclared identifier. as far as linking the the winspool.lib file plzz explain it a little more wht i have done is in the project settings of VC i have linked the winspool.lib file. take care One thing more when i chaged the version it gave the error then after some time it started working but with the same error. i m using win 2000 professional edition. any help will be appreciated alot
-
Hi joel I still get the same error undeclared identifier. as far as linking the the winspool.lib file plzz explain it a little more wht i have done is in the project settings of VC i have linked the winspool.lib file. take care One thing more when i chaged the version it gave the error then after some time it started working but with the same error. i m using win 2000 professional edition. any help will be appreciated alot
You probably need to get the latest PlatformSDK from Microsoft. Joel Lucsy