Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / dbExitPrompt ( ) gives errors

Author
Message
Steve O
AGK Bronze Backer
20
Years of Service
User Offline
Joined: 24th Feb 2004
Location: The Netherlands
Posted: 13th Dec 2004 23:38
this command:


gives errors when used like this:


these are the errors:
Quote: "
Compiling...
main.cpp
main.cpp(37) : error C2664: 'dbExitPrompt' : cannot convert parameter 1 from 'const char [6]' to 'DWORD'
This conversion requires a reinterpret_cast, a C-style cast or function-style cast
"


what's up with that???...it should just work because i pass correct values to it!

IanM
Retired Moderator
22
Years of Service
User Offline
Joined: 11th Sep 2002
Location: In my moon base
Posted: 14th Dec 2004 01:21 Edited at: 14th Dec 2004 01:21
It's definitely a bug.

Try putting the following code into your source file near the top:



Hopefully that should sort it out. If not, then it's back to Mike ...

*** Coming soon - Network Plug-in - Check my site for info ***
For free Plug-ins and source code http://www.matrix1.demon.co.uk
Steve O
AGK Bronze Backer
20
Years of Service
User Offline
Joined: 24th Feb 2004
Location: The Netherlands
Posted: 14th Dec 2004 01:31
well, i dont get any errors anymore, just warnings, but the command doesnt seem to do anything

IanM
Retired Moderator
22
Years of Service
User Offline
Joined: 11th Sep 2002
Location: In my moon base
Posted: 14th Dec 2004 01:53
Well, what warnings do you get???



Here's a temporary replacement - just replace that function I've already given you:



*** Coming soon - Network Plug-in - Check my site for info ***
For free Plug-ins and source code http://www.matrix1.demon.co.uk
Steve O
AGK Bronze Backer
20
Years of Service
User Offline
Joined: 24th Feb 2004
Location: The Netherlands
Posted: 14th Dec 2004 02:25
that way it works! thnx!

the warnings were:
Quote: "
Compiling...
main.cpp
main.cpp(18) : warning C4311: 'type cast' : pointer truncation from 'char *' to 'DWORD'
main.cpp(18) : warning C4311: 'type cast' : pointer truncation from 'char *' to 'DWORD'
Linking...
Creating library Release/test.lib and object Release/test.exp
"


...but now they dont appear anymore with the new code you gave me.

IanM
Retired Moderator
22
Years of Service
User Offline
Joined: 11th Sep 2002
Location: In my moon base
Posted: 14th Dec 2004 02:46
Those warnings can be ignored. They appear because you have the 'Detect 64-bit Portability issues' set to Yes. It's not a problem if you switch that option to No.

*** Coming soon - Network Plug-in - Check my site for info ***
For free Plug-ins and source code http://www.matrix1.demon.co.uk
Steve O
AGK Bronze Backer
20
Years of Service
User Offline
Joined: 24th Feb 2004
Location: The Netherlands
Posted: 14th Dec 2004 05:03
well thats ok, i dont care about warnings anyway, as long as there are no errors while compiling.

Mike Johnson
TGC Developer
22
Years of Service
User Offline
Joined: 13th Sep 2002
Location: United Kingdom
Posted: 14th Dec 2004 05:08
I will get this one fixed for the next upgrade. Must have missed it out on the list of castings.

Mike

Login to post a reply

Server time is: 2024-11-18 21:42:50
Your offset time is: 2024-11-18 21:42:50