|
what language? C? C++? MFC? what kind of string? isn't there some documentation on the language and strings you are using?
|
|
|
|
|
"Best" is a subjective term and only you can answer what is best for your situation. Have you looked at strchr() ?
"One man's wage rise is another man's price increase." - Harold Wilson
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
"Man who follows car will be exhausted." - Confucius
|
|
|
|
|
TCPMem wrote: What's the best way to find newline in char[]
Searching for.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
you mean Google? Bing? Baidu?
|
|
|
|
|
No, I meant, you know, for , if , ...
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
hello guys... what does these three lines of code mean...thnx
#if _MSC_VER > 1000
#pragma once
#endif
|
|
|
|
|
#pragma once is an include guard: the file will be included only once. This is similar has having the text in the file wrapped into a
#ifndef .....
#define
#endif
section.
I think this pragma was not available in the first versions of the compiler (_MSC_VER), that is why it is wrapped into the #if/#endif section.
|
|
|
|
|
and what is this??
_MSC_VER > 1000
|
|
|
|
|
If the compiler version is higher than version 10 (not sure, you have to google to see how the versions are encoded), then the pragma is used.
|
|
|
|
|
functionality gets added to windows all the time, and data structures sometimes get expanded. To cope with these, Microsoft has one overall version number in _MSC_VER, which they use to have their header files adapt to the situation.
Example: since Vista, the LVITEM struct has some new fields.
|
|
|
|
|
They hide it inside the documentation.
--Led Mike
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
CPallini wrote: They hide it inside the documentation.
Bastards!
|
|
|
|
|
who boss...... ayyo ayyo yo
|
|
|
|
|
BTW, it's been a very long time I didn't see him !
|
|
|
|
|
Sadly he left because of 'HOW TO ANSWER A QUESTION', see his profile page.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
Starting to think people post kid pics in their profiles because that was the last time they were cute - Jeremy.
|
|
|
|
|
Hi!
I've declared a struct named CameraType globally in a file called GameManager.h. I'm trying to access it like this: CameraType cType; in a file called GamePlayState.cpp. I got the following error:
IntelliSense: identifier "CameraType" is undefined d:\goldminer\source\game\gameplaystate.cpp 109
I've also included the GameManager.h file to the GamePlayState.cpp file. How to overcome this error?
|
|
|
|
|
Hoe did you declare the structure ? Show some code please.
|
|
|
|
|
struct CameraType
{
core::vector3df FRONTCAM;
core::vector3df BEHINDCAM;
core::vector3df TOPCAM;
};
|
|
|
|
|
what camera model boss .. Try Sony CameraType its 14 megaPixel really its gud no Error will come .. Thanks ..Please Try after using this..
|
|
|
|
|
did you include gamemanager.h ?
#include "GameManager.h"
Watched code never compiles.
|
|
|
|
|
I've already included. The proble is solved by declaring the structure as const. Is it a good approach?
|
|
|
|
|
Declaring something as const mean that you will not need to modify it later. It's very strange that changing your declaration to const fixed the problem, anyway I think that it's a bad approach.
Can you post a code snippet of your declaration?
|
|
|
|
|
Sauro Viti wrote: Can you post a code snippet of your declaration?
const struct CameraType
{
core::vector3df FRONTCAM;
core::vector3df BEHINDCAM;
core::vector3df TOPCAM;
};
|
|
|
|
|
A misunderstanding: I meant the line of code on the .cpp file that gave you the error
|
|
|
|