|
Have you tried setting a 'watch'?
Software Zen: delete this;
|
|
|
|
|
Hello,
I am using VC++ 7.0 and I am having some trouble. I am trying to build a solution with multiple projects. All but one of the projects is set to produce a .lib (Configuration Type) as opposed to an .exe or .dll etc.
Some of the projects depend on and use functions from others.
The problem I am having is this:
Visual Studio seems to be automatically inserting library files into the (presumably lib) command line arguments that I did not specify. In other words, when I open the project fresh, those libraries do not appear in the command line. But then when I build, they suddenly appear.
The result seems to be that I am inundated with many of the warning LNK4006.
Has anyone had this problem or know what I am doing incorrectly?
Thanks
John
|
|
|
|
|
I try to write the LF(#10) char to a file using putc() but it automatically add the CR(#13) before LF. Is there anyway write only the LF char? Thanks.
|
|
|
|
|
Try open the file in binary mode...
Just an idea.
- Anders
Money talks, but all mine ever says is "Goodbye!"
|
|
|
|
|
I recently loaded Visual.net 7.0. I had been running an earlier version on another machine. I am now getting the following error message, the name of the program is CorpStrat.exe
'CorpStrat.exe': Loaded 'C:\CorpStratRes\CS2\Debug\CorpStrat.exe',
Symbols loaded.
'CorpStrat.exe': Loaded 'C:\WINNT\system32\NTDLL.DLL', Cannot find or
open a required DBG file.
'CorpStrat.exe': Loaded 'C:\WINNT\system32\KERNEL32.DLL', Cannot find or
open a required DBG file.
The program '[1812] CorpStrat.exe: Native' has exited with code 1 (0x1).
I am at a loss here. Any suggestions?
Al
|
|
|
|
|
It only means that you don't have the Windows Debugging Symbols installed, and that's why it can't load the symbol files (.dbg) for the system dll's.
Don't worry, it's not an error.
You use the symbols when you watch your "call stack" window, then you can see the actuall function names, instead of just the offsets, in the windows dll's.
- Anders
Money talks, but all mine ever says is "Goodbye!"
|
|
|
|
|
Is there a way to have "true" symbolic variable ?
I'm pretty sure that I'm not explaining myself correctly, the situation is that I
have some #define that represent the type/state of some object.
#define STATE_UNDEFINED 0
#define STATE_SOMESTATE 1
#define STATE_SOMEOTHERSTATE 2
and I have a variable somewhere
int someState = GetState();
if ( someState )
{
}
The question, is there a way to make the state thingy really symbolic ?, not an int, char, or something else ? that I have to explicitly set and/or equal to the whole symbol ?
I'd like to prevent the user to think and abuse the fact that it's an int !
Max.
|
|
|
|
|
I believe that's one of the problems enumerated values solve:
enum State { Undefined, SomeState, SomeOtherState };
State state = GetState();
Is this what you're talking about?
Regards,
Alvaro
Well done is better than well said. -- Benjamin Franklin
|
|
|
|
|
It's better, but I can still abuse the fact that enums are int.
State myState = 0;
Not in C++ but in C it's working ! since I'm working with a mix of C and C++
Max.
|
|
|
|
|
Well, enums are the closest thing you'll ever get to symbolic manipulation in C++ I'm afraid.
If you want symbolic manipulation, please see the Lisp-family. It was designed for it, and it excels at it.
--
standing so tall, the ground behind
no trespassers, on every floor
a garden swing, and another door
she makes it clear, that everything is hers
A place of abode, not far from here, Ms. Van de Veer
|
|
|
|
|
Hi everyone,
I'm new to C++ programming and i'm still learning, i was just wondering if its possible to execute a dos comman in C++? like the command FINDSTR, why i want to use this? because no doubt about it its fast when it comes to searching for a particular text in a file, and since my project is about searching i thought this is a good idea. Please if you know how kindly help me.
Thanks/Regards
Sidney
Thanks/Regards
Sidney
|
|
|
|
|
Yup:
#include <process.h>
int main( )
{
system( "dir *.txt" );
return 0;
}
Wenn ist das Nunstück git und Slotermeyer? Ja! Beierhund das oder die Flipperwaldt gersput!
|
|
|
|
|
Thank you very much i will now try this.
Thanks/Regards
Sidney
|
|
|
|
|
when a system start or some one login into some os then os perform some inilizaion for a little amount of time depending upon the software and harware.
may i find out the amount of initilization time ?
i am requiring this because my service is running on the system and it has to perform some steps after initialization or after some on login's.
and i could not find the initialization time of the os yet because its different depening on software and hardware.
how to find out ?
any body could tell plz.
r00d0034@yahoo.com
|
|
|
|
|
I don't think you can, it depends on so much factors, software, hardware, ...
Your service should not be dependant on "time", no software should be dependant on "time" like that, except for real time software.
But there might be something in the OS that indicate that the system is "ready".
Max.
|
|
|
|
|
u have to check out the dependency stuff for service startup to make sure any other services urs depends on are initialised and running before u do
im working thru this myself
"traffic lights are for people who can't make their own decisions" biz stuff about me
|
|
|
|
|
Does anyone know of good skin libraries? Free is always better? I was looking into skins, just for kicks. Thanks for the leads.
"Best file compression around: DEL *.* = 100% compression."
<><><><><><><><><><><><><>
Matthew R. Miller
mattrmiller@computersmarts.net
www.computersmarts.net
|
|
|
|
|
|
You Bet! Thanks a bunch. I searched google for this kind of stuff but got millions of hits, no matter which way I put it.... no offense to google it's just too good in these situations. Thanks again.
"Best file compression around: DEL *.* = 100% compression."
<><><><><><><><><><><><><>
Matthew R. Miller
mattrmiller@computersmarts.net
www.computersmarts.net
|
|
|
|
|
Can someone explain me what's the difference?
Sounds like a dump question.... I really don't know it. From previous Windows MFC code I am used to use BOOL , but why is that? C++ does provide a native type bool , shouldn't I use it?
Thanks!
|
|
|
|
|
BOOL is Windows/MFC
bool is Standard C++
Max.
|
|
|
|
|
BOOL is 4 bytes
bool is 1 byte
BOOL is a typdef'ed int for TRUE/FALSE operations in the Windows API
bool is a type safe true/false value in C++
"VB the polished turd of software languages"
|
|
|
|