|
Hi,
I have created an application in vc++ using mfc. The application connects to Access database. I have used DAO. The application is multi-user one. It works like this:
When the user creates a new account, a new .mdb file is created and then two tables and fields are created at runtime.
It has editable listview control, graphs -pie chart/bar graph, a password-hashing algorithm.
Some of the class I got from CodeProject and then modified them to my need.
The program does not use registry keys or any complicated programming.
I did most of the program on one xp system. I had to change the system due to some reason. When I was working on the new XP system, the computer would restart by itself. It wouldn’t happen at regular intervals. I assumed that there was something wrong with the system. After a while it totally crashed.
I switched back to my old system and completed the program. When I send it to a friend, he worked the program for a while, after which his computer too started restarting by itself.
I worked the program on two other systems, but nothing happened.
I am wondering why is the system failure occurring on some systems.
I just can’t understand whether it is my program that is causing this to happen. If so, why is it not happening in all the systems? The program does not use the windows registry or any complicated codes.
If anybody knows about this please help.
Thanks,
Tara
Fortitudine Vincimus!
|
|
|
|
|
Have you checked if the memory is OK? Try memtest.
|
|
|
|
|
pgrohs wrote: Have you checked if the memory is OK?
Please can you tell me which memory.
pgrohs wrote: Try memtest.
I do not know about memtest. Please can you explain in a little more detail.
Is the problem with my program?
Fortitudine Vincimus!
|
|
|
|
|
Look at http://www.memtest.org/.
This is a tool that checks your RAM. It happens that programs crashes without an obvious reason. In that case it is useful to check the memory to exclude a hardware problem.
|
|
|
|
|
Why is it that it on the two system that I worked on nothing happened, but on a third system, the same program is behaving this way?
Fortitudine Vincimus!
|
|
|
|
|
What do you mean with "system"? The OS or the hardware?
|
|
|
|
|
The OS,I guess, Windows XP
Fortitudine Vincimus!
|
|
|
|
|
This is what is showing on my computer that crashed.
Windows could not start because the following file is missing or corrupt:
<Windows root>\system32\hal.dll
Please re-install a copy of the above file.
Did my program cause this to happen?
Fortitudine Vincimus!
|
|
|
|
|
Just google a little bit.
|
|
|
|
|
I did google. Mostly what comes up is: people have the same program. They are told that it is because the system heats up too much or because of windows update restarting the system. Thins like that.
I need to know whether there is something wrong with my program. Is there any remote possibility that my program is causeing this?
I am finding it difficult to figure it out because on my system the program works fine. Its working fine on another computer too. Does that mean anything? That nothing is wrong with my program.
Fortitudine Vincimus!
|
|
|
|
|
Tara14 wrote: They are told that it is because the system heats up too much or because of windows update restarting the system. Thins like that.
So have you ruled both of these possibilities out?
"The largest fire starts but with the smallest spark." - David Crow
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
I do not know what to think. I managed to reinstall windows on the system that crashed and worked my program again on it for a long time and nothing happened. It has not restarted at all. So I am totally confused. The program has to work on the clients system...
Fortitudine Vincimus!
|
|
|
|
|
You would have to be doing something awfully odd to crash a properly configured XP system by anything you're doing. On the other hand, this is MS; if there is a way to 'tard something up they'll find it.
What exactly did you have to change on your system? Do these systems that are crashing crash under heavy load from other apps? Do you have spyware / trojans / viruses on these machines?
|
|
|
|
|
earl wrote: Do these systems that are crashing crash under heavy load from other apps? Do you have spyware / trojans / viruses on these machines?
No. The sysems are properly protected.
earl wrote: You would have to be doing something awfully odd to crash a properly configured XP system by anything you're doing. On the other hand, this is MS; if there is a way to 'tard something up they'll find it.
That is exacly what I thought too. And my program uses all the usual very simple dialog boxes, some calculation, no registry used, no dll's, no multiple threds, no internet connection....
I have added
AfxGetModuleState()->m_dwVersion = 0x0601;
at the begining to connect to dao360.
The best part is that on two other system no restarting has happened.
But of course, the client is going to blame my program if his system crashes.
Fortitudine Vincimus!
|
|
|
|
|
To use Cmutex Object , Any headerfile have to include ?
I have not include Header file .
I'm geating error :
----------------------------------------------------------------------
lets : CMutex g_m;
- - - - - - - - - - - - - - - - - - - - - -
E:\Project-MFC\UiThread1\UiThread1Dlg.cpp(17) : error C2146: syntax error : missing ';' before identifier 'g_m'
E:\Project-MFC\UiThread1\UiThread1Dlg.cpp(17) : error C2501: 'CMutex' : missing storage-class or type specifiers
E:\Project-MFC\UiThread1\UiThread1Dlg.cpp(17) : fatal error C1004: unexpected end of file found
------------------------------------------------------------------------
Thanks to all.
-- modified at 6:02 Monday 10th July, 2006
|
|
|
|
|
#include <afxmt.h>
Ovidiu Cucu
Microsoft MVP - Visual C++
|
|
|
|
|
Yes it is working. Thanks a lot.
|
|
|
|
|
Hey all,
In my application, I need to turn on the timer once the Pc sends a packet to the serial device. the serial device should respond immediately to teh PC's request. The Pc should get response from the serial device within "m" secs. the Pc will wait for response from serial device and check for the timer. if elapsed, will resend the packet again.
in brief,
On_send(wparam,lparam)
{
//packet sent to serial device
//timer has to be triggered on here
}
On_rx(wparam,lparam)
{
//checks for packet received
//if no packet received from serial device, then
{
//check for timer
while(timer has elapsed)
{
//resend the packet to MPU
post_message(WM_RESEND,null)
}
}
}
On_resend(wparam,lparam)
{
//send same packet to PC
here, I have to restart the timer again to see if the
serial device responded within particular time as in On_rx.
}
this is the idea i have in mind. but i dont know how to implement. Can I use WM_TIMER...? I know there are various timers like multimedai timers, etc., But dont know which one suits my need as I am still in the learning curve of MFC.
I would appreciate if anyone can help me with this.
Thanks in advance.
|
|
|
|
|
WM_TIMER would be best bet.. if you are beginner in MFC
"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
|
|
|
|
|
Check out SetTimer() .
"The largest fire starts but with the smallest spark." - David Crow
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Hi All,
I have a typical windows application that requires many dll's to work properly. One of the dll's generated during build process is actually a dummy dll (functions simply returns). This dll is supposed to be replaced by a third party dll with same function signatures.
Now the issue is
1. The Dll generated by the build process is a Win32 console dll, where as the third party dll I have is win32 GUI subsystem.
2. Even though the subsystems are different but actually the dll has simple C methods, nowhere using GUI stuff at all, so by simply replacing the dummy dll with the 3rd party dll should the things work.
Thanks and Regards.
|
|
|
|
|
As long as the functions in the dummy dll are declared in exactly the same way as the third party dll, then replacing the two dlls will work fine.
Dave Kerr
codechamber@hotmail.com
http://www.codechamber.com
|
|
|
|
|
plz tell me about the websites which help me in finding code and other problems in c++,vc++
thanks
Ashish Dogra
MCA
Noida
|
|
|
|
|
ashish dogra wrote: plz tell me about the websites which help me in finding code and other problems in c++,vc++
you are already on that site!
"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
|
|
|
|
|
thanks for your reply sir
but i want to know much more
plz tell me
thanks
Ashish Dogra
MCA
Noida
|
|
|
|