Login ProductsSalesSupportDownloadsAbout |
Home » Technical Support » ElevateDB Technical Support » Support Forums » ElevateDB General » View Thread |
Messages 1 to 4 of 4 total |
#include <shlobj.h> clash with Elevate edbenv.hpp |
Wed, Jun 8 2011 9:18 PM | Permanent Link |
IQA | Hi All,
I use an #include <shlobj.h> in my program to access SHGetFolderPath and grab various folder paths for the Windows version being used and this works perfectly. I can grab theCSIDL_COMMON_APPDATA or the CSIDL_LOCAL_APPDATA and so on. Trouble is when I include the ElevateDB components in the program it appears to clash with shlobj.h On compiling it brings up edbenv.hpp on line128, 129 and 130: static const System::ShortInt CSIDL_PERSONAL = 0x5; static const System::ShortInt CSIDL_LOCAL_APPDATA = 0x1c; static const System::ShortInt CSIDL_COMMON_APPDATA = 0x23 With the error messages... [BCC32 Error] edbenv.hpp(128): E2040 Declaration terminated incorrectly [BCC32 Error] edbenv.hpp(129): E2040 Declaration terminated incorrectly [BCC32 Error] edbenv.hpp(130): E2040 Declaration terminated incorrectly Obviously there's a clash, just wondering if anyone else experiences this and if anyone can think of an easy workaround. Thanks, Phil. |
Thu, Jun 9 2011 1:15 AM | Permanent Link |
IQA | OK I worked it out. I just moved the #include <shlobj.h> after the main.h
#include "Main.h" #include <shlobj.h> This is only required when I use EDB components on the form. |
Thu, Jun 9 2011 4:00 PM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. timyoung@elevatesoft.com | Philip,
<< I use an #include <shlobj.h> in my program to access SHGetFolderPath and grab various folder paths for the Windows version being used and this works perfectly. I can grab theCSIDL_COMMON_APPDATA or the CSIDL_LOCAL_APPDATA and so on. Trouble is when I include the ElevateDB components in the program it appears to clash with shlobj.h >> What version of C++Builder are you using ? There's an IFDEF on those defines, and they should only be included for lower versions of Delphi and C++Builder that left them out of the shlobj unit. -- Tim Young Elevate Software www.elevatesoft.com |
Fri, Jun 10 2011 1:04 AM | Permanent Link |
IQA | <<
What version of C++Builder are you using ? There's an IFDEF on those defines, and they should only be included for lower versions of Delphi and C++Builder that left them out of the shlobj unit. >> I'm using C++ Builder XE Professional, although I did workaround it by moving the #include <shlobj.h> after the main.h #include "Main.h" #include <shlobj.h> But I didn't need to do that until I used EDB components on the form. |
This web page was last updated on Saturday, April 27, 2024 at 08:52 PM | Privacy PolicySite Map © 2024 Elevate Software, Inc. All Rights Reserved Questions or comments ? E-mail us at info@elevatesoft.com |