|
No that isn't it, but thanks anyway.
I had both VS6 and VS2003 installed and I think it was trying to use the wrong lib. I have now un-installed VS6 and cleared out my system path and lib variables of any reference to VS6 folders. Have re-started the PC and still have the error. At work I managed to get around the problem by telling the linker to link to a VS2003 MFC lib but I cannot now remember which one it was!
I am still getting the linker error! If anyone knows of the answer I would appreciate their input. If I solve this I will post what I did in here, in case someone else encounters the same issue.
|
|
|
|
|
Andy H wrote: No that isn't it
Sure? AFAIK you MUST initialize static members.
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.
|
|
|
|
|
That is true, but maybe he's just not showing us that he has initialized it in his .cpp file. He should make it clear to us whether he has or has not done this.
|
|
|
|
|
I agree, on the other hand, the Linker error message content supports my hypothesis...
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.
|
|
|
|
|
class A<br />
{<br />
public:<br />
virtual void f(){cout << "I'm into base \n";}<br />
};<br />
<br />
class B : public A<br />
{<br />
public:<br />
virtual void f(){cout << "I'm into derived \n";} <br />
};
In the above code will there be two virtual tables that will be created or the creation of a virtual table depends on what objects is being created. Lets say if a pointer to derived class B is obtained by doing a static_cast on the pointer returned from a dynamic creation of object of class A when I see the debugger it shows the __vfptr to some address with const A::'vftable'. Does it mean that there is only one vtable that is created.
So basically the query boils down to the fact that how many vtable are created on declaration of classes with virtual functions.
|
|
|
|
|
tom groezer wrote: So basically the query boils down to the fact that how many vtable are created on declaration of classes with virtual functions.
One vtable per class (not per object). Each object with virtual functions contains one (hidden) pointer to one vtable. At least that's an educated guess because compilers are free to implement polymorphisms any way they want, even without a vtable mechanism.
|
|
|
|
|
Since Class A is part of class B, they will use common Virtual Table
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
Support CRY- Child Relief And You
|
|
|
|
|
Hi,
I have a workspace in VS 6.0. This workspace contains 10 projects, each project depends one or other. Since one project is dependant of other, the projects should be built in an order, so that a particular project will get built only after building its dependencies. This will avoid the build error (lib file not found/open or like link error).
But when I tried to build the workspace, it is building the project as in the order in the workspace (but not in the order we required). So can any one help me how to build all the projects in a workspace in a required order?
My guess, one way to solve the problem is, making use of Make file. But I never worked with Make file. If my guess is correct, can any one help me how to use Make file.
Also please let me know, if there is any other way to build the projects in a workspace can be build in a required order.
- Nandu
|
|
|
|
|
I don't know for VC6 but in Visual Studio 2005 you can right click on a project and select 'Project Dependencies'. There, you can check all the projects that are required for this project to be built. The build order will be set automatically.
I suppose there is something similare in VC6.
|
|
|
|
|
But I could find one for VS 6.0 (VC++ projects - this i forget to mention above). Can any one help me if there is any similar settings for VS 6.0.
-
Thanks in advance
Nandu
|
|
|
|
|
Cedric Moonen wrote: I suppose there is something similare in VC6.
Yes, and the menu items to get there sound identical (where most other things have been moved and/or renamed).
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Nandu_77b wrote: I have a workspace in VS 6.0. This workspace contains 10 projects, each project depends one or other. Since one project is dependant of other, the projects should be built in an order, so that a particular project will get built only after building its dependencies. This will avoid the build error (lib file not found/open or like link error).
Goto Project->Dependencies
The combo that you see shows a project and the list box contains entries for other projects.
Select all the projects on which the one in the combo is dependent. That's all. Select next project and proceed as with the previous one.
|
|
|
|
|
Thank you all. I am able to from Projects - dependencies
|
|
|
|
|
Hello,
is there any way to track/read the current CPU usage?
If yes pleas give me some sugestion how to do this, what functions etc. i need for that!?
ragards
termal
|
|
|
|
|
See if this gives you any ideas.
There's also the LoadPercentage member of the Win32_Processor class.
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Hello,
thanks for quick reply, i try as soon as possible!
with best regards
termal
P.S. have a nice weekend!
|
|
|
|
|
Hello,
now i try to solve my problem with cpu usage!
I can't use this clas Win32_Processor, is unknown on my system:
Win32_Processor' : undeclared identifier
what header or libraries to use for this?
Thanks
termal
|
|
|
|
|
termal wrote: I can't use this clas Win32_Processor, is unknown on my system:
Win32_Processor' : undeclared identifier
Code snippet?
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
hi
my problem is that when i boot my computer.Windows xp keep all pins of parallel port high how can i solve this problem.for my project at least pins of data register should be low until i start my program ther is any option of windows registory setting
I will be very greatfull if anybody reply me
thank u in advance
-- modified at 2:09 Saturday 14th July, 2007
|
|
|
|
|
Hi,
you can't solve this problem, this is normal.
Greetings Ralph
|
|
|
|
|
you can make all parallel port pin to low when you start the program.. what the problem in that!
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
Support CRY- Child Relief And You
|
|
|
|
|
i connect some output device like siron(speaker) they start automatically because window start to give 5 volt at that pin but i want to start when i run my program
|
|
|
|
|
Why not make the siren sound when the pin goes low?
Steve
|
|
|
|
|
Hi,
as all know, we can easily change text of menu items in respective OnUpdate()
function.
But this is (i think) possible for only Menu Items and not for Sub Menus.
I have following menu structure Tools->Application and few sub menu items in this Application menu. How can i know when the 'Application' menu item is going to be drawn or updated, otherwise how can I change text of that Item?
Please help me out...
thanx
|
|
|
|
|
A shure way is to delete the old menu items, and add the new ones.
Greetings from Germany
|
|
|
|