User forums > Using Code::Blocks

Why difference in Win32 project on C::B and VS Express 2010?

<< < (2/2)

neo1691:
I copied the same code in C::B that worked in visual studio 2010 express. first error was that it could not find kernel.lib. I fixed that by adding the lib in the linker settings. Next error was cannot find rc.exe so i added the path containing rc.exe in additional paths in compiler settings.

Now it says this

||=== hello windows using cb, Debug ===|
resource.h|1|fatal error RC1015: cannot open include file 'windows.h'.|
||=== Build finished: 1 errors, 0 warnings (0 minutes, 0 seconds) ===|


But the same code compiled well in MS VS 10

Jenna:

--- Quote from: neo1691 on December 23, 2011, 09:47:04 am ---I copied the same code in C::B that worked in visual studio 2010 express. first error was that it could not find kernel.lib. I fixed that by adding the lib in the linker settings. Next error was cannot find rc.exe so i added the path containing rc.exe in additional paths in compiler settings.

Now it says this

||=== hello windows using cb, Debug ===|
resource.h|1|fatal error RC1015: cannot open include file 'windows.h'.|
||=== Build finished: 1 errors, 0 warnings (0 minutes, 0 seconds) ===|


But the same code compiled well in MS VS 10

--- End quote ---
It should also compile, if you use msvc10 as compiler in VC::B, but will in almost any cases fail, if you use (e.g.) MinGW as compiler.

neo1691:

--- Quote from: jens on December 23, 2011, 09:50:39 am ---
--- Quote from: neo1691 on December 23, 2011, 09:47:04 am ---I copied the same code in C::B that worked in visual studio 2010 express. first error was that it could not find kernel.lib. I fixed that by adding the lib in the linker settings. Next error was cannot find rc.exe so i added the path containing rc.exe in additional paths in compiler settings.

Now it says this

||=== hello windows using cb, Debug ===|
resource.h|1|fatal error RC1015: cannot open include file 'windows.h'.|
||=== Build finished: 1 errors, 0 warnings (0 minutes, 0 seconds) ===|


But the same code compiled well in MS VS 10

--- End quote ---
It should also compile, if you use msvc10 as compiler in VC::B, but will in almost any cases fail, if you use (e.g.) MinGW as compiler.

--- End quote ---

I have both MinGW and MS VS 10.
This time my compiler is set to MS VS 10 (in c::b)
It compiled a simple Hello world program, however it had given one warning.

But now i want to compile a win32 gui project and it gives this error..

PS: The default compiler is VS 10 and the compiler used for the project is also VS 10

Navigation

[0] Message Index

[*] Previous page

Go to full version