|
Bankey Khandelwal wrote: please help me.....ASAP
That is what the forum is for.
Bankey Khandelwal wrote: i have to make a application which fetch data from other machine so i have make application which transfer messeges between two machine but i want total data at client side .
That is what the forum is not directly for (provide complete solutions). Try and google for socket, client, server or something in this taste, or even search on Code Project using the search functionality at the top of this page.
~RaGE();
|
|
|
|
|
Write a COM (DCOM) object.
Steve
|
|
|
|
|
Bankey Khandelwal wrote: i have to make a application which fetch data from other machine so i have make application which transfer messeges between two machine but i want total data at client side .
http://www.codeproject.com/internet/#Client%2FServer+Development[^]
"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
|
|
|
|
|
Hi,
I am woking on VC++ project. When I run the project in Release mode, I am getting R6025 Runtime error message. The project has hundreds of virtual functions not written by me and I have no clue as to find out from where this message box is coming? If I run in debug mode, I am not getting this error message box. If I try to debug in release mode, I am still not getting this error message. Can anyone please guide me as to how to trace out the cause for thsi problem?
Thanks
Madhavi
|
|
|
|
|
|
As you're probably aware, this means that you called a pure virtual function. At first sight this seems impossible - But it is not. What's more, in general, such errors can't be caught at compile time. Here is some code that shows how this can happen:
#include <iostream>
using namespace std;
class Base
{
public:
virtual VirtualFunction() = 0;
};
void UseIt(Base *pBase)
{
pBase->VirtualFunction();
}
class Base2 : public Base
{
public:
Base2()
{
UseIt(this);
}
};
class Derived : public Base2
{
public:
Derived()
{
}
virtual VirtualFunction()
{
cout << "Derived::VirtualFunction\n";
}
};
int main(int argc, char* argv[])
{
Derived d;
return 0;
}
It happens because you are calling a virtual function in a function that is called from a constructor (and the object is partially constructed).
To debug it I would launch it in the debugger and when the error dialog appears break and look at the call stack. If it only happens in a release build, build a release build with debug info and follow the procudure above - Debugging with a map file isn't needed when you do this, it's the hard way.
Steve
|
|
|
|
|
Hi Stephen Hewitt,
Thanks for your help. I understood the concept here.. I went through the aricle available at:
|
|
|
|
|
Hi ,
Thanks for your help..I understood the concept here.. The problem is that there are hundreds of virtual functions in the project that are not written by me and moreover I get this exception only in release mode. If I run the application in release with debug information, I am still not able to reproduce this exception. So is there any way to find out from where this exception is coming while running in release mode?
Thanks
Madhavi.
|
|
|
|
|
Building a release build with debug info will not alter the way the application behaves. To turn on debug info for the release build follow these steps (VC6):
- Select the release configuration as the active config.
- Project settings, "C/C++" tab, "General" category: Select "Program Database" in the "Debug Info" combo.
- "Link" tab, "Debug" category: Tick "Debug info", "Microsoft format" & "Separate types".
- Rebuild.
If your workspace contains multiple projects follow the same steps for each one. Run the application in the debugger (still the release build however) and reproduce the problem. When the error dialog appears break in and look at the call stack. You may have to hunt for the correct thread.
Because optimizations are enabled your debugger will "lie" to you from time to time (when some optimization trips it up) so beware.
I actually always follow these steps for release builds. Having the .PDB files has many benefits such as simplifying postmortem analysis with crash dump files. In a production environment you should have a symbol server on the build machine and the .PDB files get added to the symbol server as part of the build process.
Steve
|
|
|
|
|
Hi,
Thanks for your reply..
This crash occurs only in release mode. It does not occur If I set the bebug information(i.e Link->GenerateDebugInfo settings ) in release mode. Moreover this does not reproduce in release mode always..It comes up some times only..i.e I don't have the steps for repeating this error. Hence I don't think it is problem with virtual function call. If it was a problem with virtual function call, I should be able to reproduce this error always in both debug and release builds ..right? Is there any other reason for this error message? Do my Link options of Project settings have any impact on this error? My link options are: CTS32D.LIB RTS32D.LIB TAPI32.LIB VERSION.LIB WINMM.LIB VFW32.LIB..
Please let me know if you have further inputs on this as I am not getting any clue for resolving this issue..
Is there any tool that can catch and take us to the code that is creating these runtime errors..
Thanks..
Madhavi..
|
|
|
|
|
Hi All,
I would like to know whether DiectX 9 supports vc++6? Moreover I'd also like to know the best books available in the market for DirectX9.
Thanks in Advance
Rajeev
|
|
|
|
|
i need a simple doc/view architecure
example,
just want to clear up fundamental
Vikas Amin
Embin Technology
Bombay
|
|
|
|
|
This is something you can find without any problem in the MSDN.
~RaGE();
|
|
|
|
|
Yeh i had refered one good book but
its not with me right now , any way
will find it from net.
Vikas Amin
Embin Technology
Bombay
|
|
|
|
|
|
How to get a pointer of a specific child frame window in a MDI application if I have open more child frame windows?
sude
|
|
|
|
|
There are multiple way to achieve this. Enumerate all windows and check with CWnd::IsChild , use CWnd::GetWindow with parameter GW_CHILD, use CWnd::FindWindow , this will all depend on the criteria that makes the child window you search different from the others (the name, the ID, ...)
~RaGE();
|
|
|
|
|
First of all, thank you for reading this message.
As a novince, what I have seen so far is to put a button into a dialog, and it will stay at that position staticly. Now if I resize the window, the button is still there..
Could you please tell me or explain to me what method i need to approach to move the button (in the same way that DOCK in C# works)
Thank you.
Elapid For The Win
|
|
|
|
|
MoveWindow or SetWindowPos apis will do that.
-Prakash
|
|
|
|
|
In addition with Mr.Prakash, I would suggest you to use this[^] class.
It will be useful to you, if you decide to move other controls as well.
"Success is the ability to go from one failure to another with no loss of enthusiasm." - W.Churchill
|
|
|
|
|
Hi,
I am using SECDialogBar class inside mainframe.cpp , during my application exit and startup my dialogbar settings are getting written into .ini file. the standard framework is providing this by default, Is there a way to prevent it from reading and writing into ini file ? I want this behaviour for all dialogbars in the application except one, for this one dialogbar I want to control writing into ini file.
If you have any idea please let me know asap.
Krishna
|
|
|
|
|
Hi ,
I am using WinHelp2000 for dislaying Help on my application in VC++.
The help is displayed based on the language my application is being executed.
Lets say I can run my application in English and Italian.
The appropriate help file is loaded when i start the application, based on the language selected.
Now the problem is if I do not have help on a specific topic in Italian,then I should be able to display help on that topic in English.
If anyone knows a solution to this ,kindly help me.
Thanks,
Gayathri.
|
|
|
|
|
I am pretty sure if you call WinHelp, that you can detect if the requested topic was located. If not located, then open the OTHER help file and try to get the topic again. Default implementations of WinHelp calls typically do very little, if any, checking on the return status values of the function calls.
Marriage slows down your coding, a baby slows it down even more!
|
|
|
|
|
Hi ,
The problem itself is that though I am able to call Winhelp,I am not able to detect if the requested topic has been located or not.
WinHelp returns a value of TRUE even if it doesnt detect a topic and this is where I am stuck up.
If I can resolve this ,my problem is solved.
The Code snippet I am using is
::WinHelp(HWnd, HelpFilePath, HELP_CONTEXT, HelpTopic );
Thanks,
Gayathri
|
|
|
|
|
Typical MS BS
I did some experimentation, and indeed I observed the 'success' return value for an invalid topic - but no help window appeared whatsoever. I thought to check GetLastError and got a '5' back. However, when I called WinHelp asking for the contents, I got a success back (no surprise there) but GetLastError also again returned a '5'.
My summary is that this poorly documented or incorrectly written function (WinHelp) makes it impossible to disinguish between successful outcomes and failures.
Marriage slows down your coding, a baby slows it down even more!
|
|
|
|