468,251 Members | 1,360 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 468,251 developers. It's quick & easy.

weird error when precompiling genwin.mak with nsqlprep

I am trying to compile the sample program genwin.sqc, using nsqlprep
which is used to precompile embedded sql in C. I am getting weird
errors and that is because windows.h is included in the genwin.sqc
file. I am using

Setting the lib and include path:

set INCLUDE=C:\Program Files\Microsoft SQL
Server\80\Tools\DevTools\include;C:\Program Files\Microsoft SQL
Server\80\Tools\DevTools\Samples\esqlc;%include%
set LIB=C:\Program Files\Microsoft SQL
Server\80\Tools\DevTools\lib;%lib%
Precompiling:

nsqlprep genwin /NOACCESS

Microsoft (R) Embedded SQL for C Pre-Compiler. Version 8.00.194.
Copyright (c) Microsoft Corp 1993-1998. All rights reserved.
Warning: genwin.sqc, line 7978: syntax error.
}
Warning: genwin.sqc, line 7987: syntax error.
}
Warning: genwin.sqc, line 71840: syntax error.
__declspec void __stdcall DragAcceptFiles(HWND,BOOL
Warning: genwin.sqc, line 71842: syntax error.
__declspec HINSTANCE __stdcall ShellExecuteA(HWND hwnd
Warning: genwin.sqc, line 71843: syntax error.
__declspec HINSTANCE __stdcall ShellExecuteW(HWND hwnd
Warning: genwin.sqc, line 71858: syntax error.
__declspec INT __stdcall ShellAboutA(HWND hWnd
Warning: genwin.sqc, line 71859: syntax error.
__declspec INT __stdcall ShellAboutW(HWND hWnd
Warning: genwin.sqc, line 71941: syntax error.
HWND
Warning: genwin.sqc, line 71946: syntax error.

As soon as i remove windows.h, the errors disappear. It seems nsqlprep
doesnt like windows.h. How do i get over this.
Would really appreciate if u can help me out.

versions:
OS: windows 2000 server service pack 2
VC++: version 6.0
SQLserver 2000: 8.00.194, RTM, Standard edition

Thank you
Amit
Jul 20 '05 #1
1 2585
amit (ak*****@mn.rr.com) writes:
I am trying to compile the sample program genwin.sqc, using nsqlprep
which is used to precompile embedded sql in C. I am getting weird
errors and that is because windows.h is included in the genwin.sqc
file. I am using

Setting the lib and include path:

set INCLUDE=C:\Program Files\Microsoft SQL
Server\80\Tools\DevTools\include;C:\Program Files\Microsoft SQL
Server\80\Tools\DevTools\Samples\esqlc;%include%
set LIB=C:\Program Files\Microsoft SQL
Server\80\Tools\DevTools\lib;%lib%


Since windows.h is not in any of the directories above, you must have it
somewhere else.

I have also had problems with getting funny errors with various include
files for a DB-Library module that I have. Since I am not really a C
programmer, I just moved the include files around, until I had things
working.

As I recall, when I started to use VC7, I got into new problems. So, if
you are using VS .Net, but also have VC6 available, try using VC6 instead.

--
Erland Sommarskog, SQL Server MVP, so****@algonet.se

Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techinf...2000/books.asp
Jul 20 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

3 posts views Thread by redneck_kiwi | last post: by
1 post views Thread by Endif | last post: by
2 posts views Thread by Balasubramanian Ramanathan | last post: by
3 posts views Thread by archsg | last post: by
reply views Thread by P Pulkkinen | last post: by
reply views Thread by NPC403 | last post: by
reply views Thread by kermitthefrogpy | last post: by
reply views Thread by zattat | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.