|
Hello All,
When I tried to build my Win32 app., it showed me the following error.
C:\Program Files\Microsoft Visual Studio\VC98\LIB\LIBCD.lib : fatal error LNK1127: library is corrupt
Error executing link.exe.
WebForm.exe - 1 error(s), 0 warning(s)
Not sure how to eliminate the error. It is regarding the corrupted library LIBCD.Lib. I also tried it with reinstalling the Visual Studio 6.0. Even that didn't rectify the error.
Can anyone please help me out ?
Thanks for prompt reply.
Nikhs
Nikhil Trivedi
Software Developer
-- modified at 7:30 Monday 9th April, 2007
Nikhs
Nikhil Trivedi
Software Developer
|
|
|
|
|
Hi all:
I'm trying to debug a program that is part of a whole VS solution, what special about this program is that it is a separate process but still part of the solution, and this program is launched by a separate "start up project". I've tried to attach this program to the start up project by "attach to process" in VS, but break point at that program's entry point just wasn't hit, it appears disable when "attach to process". Am I doing the right thing?
|
|
|
|
|
|
If you see Database section on the codeproject it has a lot of articles that I think they will be helpful for you
|
|
|
|
|
char buffer[17];
When the function is terminated at that tine I am getting stack around the variable buffer was corrupted
S.Yamini
|
|
|
|
|
yaminisridaran wrote: char buffer[17];
Probably, you are writting out of bounds for this array. Can you show, how you are using this array ?
|
|
|
|
|
Thanks for replying. I have completed it.
S.Yamini
|
|
|
|
|
When I close the File Selection Dialog by selecting cancel button or when selecting file and click ok button, the application is closing without any message. Previously I had the same problem because of Adobe Acrobat Reader and resolved after uninstalling Adobe reader. But now there is problem even I dont have Adobe reader and uninstalled Foxit reader.
No problem in other systems.
I cannot see problem in Debug mode.
Best Regards,
Suman
|
|
|
|
|
Does this question relevant to c++? or its another question
|
|
|
|
|
I want to find the cause using VC++ debugger.
Before I found some dlls of Adobe Reader was running while File Dialog was open in Call stack window. This time problem is only in release mode.
Best Regards,
Suman
|
|
|
|
|
I too had that pblm in the file selection dialog after setting the _WIN32_WINNT=0x501 . But I found that the pblm is not coming if the CFileDialog is created in heap instead of stack.
nave
|
|
|
|
|
How can we decide creating dialog in heap or stack?
Best Regards,
Suman
|
|
|
|
|
rp_suman wrote: How can we decide creating dialog in heap or stack
I though the problem is in your program. But if it is in third party applications, whats the use even if you found out its in stack or heap?
If the problem is in your application, change the creation of CFileDialog stack to heap as follows
CFileDialog *pDlg = new CFileDialog;<br />
pDlg->DoModal();<br />
delete pDlg;
nave
|
|
|
|
|
The problem is not happening if I make copy of the application exe and data used by application once. And happens again if I make copy of the copy. ie., problem in alternate copies of exe&data.
This seems little complicated and I continue debugging.
Thank you very much for great help from all!!
Best Regards,
Suman
|
|
|
|
|
Can you tell me at what line the exception happens...?
nave
|
|
|
|
|
Naveen R wrote: Can you tell me at what line the exception happens...?
Where did he indicate that it was an exception?
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
In the subject itself...
nave
|
|
|
|
|
What is the value of _WIN32_WINNT ? Does the problem happen with GetOpenFileName() ? Are you using a hook?
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
The problem was, in release mode, m_ofn.lpstrInitialDir member of CFileDialog was initialized from the corruped INI file. Debug mode it was using correct file.
I am not using _WIN32_WINNT or hook.
Thanks a lot for great help!!
Best Regards,
Suman
|
|
|
|
|
i am calling a exe file from my program which in turn calling an batch. after executing this exe compltely only, i have to open a message box. but this is posting while the batch fle is opened. i used createprocess.
CString ovpncheck1;
ovpncheck1 = "C:\\Program Files\\OpenVPN\\bin\\sample.exe";
STARTUPINFO startup;
ZeroMemory(&startup,sizeof(startup));
PROCESS_INFORMATION pInfo;
ZeroMemory(&pInfo,sizeof(pInfo));
startup.cb=sizeof(startup);
startup.dwFlags=STARTF_USESTDHANDLES;
startup.hStdInput=NULL;
CreateProcess(NULL,ovpncheck1.GetBuffer(ovpncheck1.GetLength() + 1), NULL,NULL,TRUE,CREATE_NEW_CONSOLE,NULL,NULL,&startup,&pInfo); // PROCESS_INFORMATION
WaitForSingleObject(pInfo.hProcess,INFINITE);
MessageBox("Click YES to Configure EncryptaKey VPN 2","EncryptaKey VPN",MB_YESNO|MB_ICONQUESTION);
how to open the messagebox only afetr executing the exe completely
Arise Awake Stop Not Till ur Goal is Reached.
|
|
|
|
|
Create a Hint (That can be a simple file or an registry end) at the
end of the execution of the batch file or the exe (if src is available).
CreateProcess(NULL,ovpncheck1.GetBuffer(ovpncheck1.GetLength() + 1), NULL,NULL,TRUE,CREATE_NEW_CONSOLE,NULL,NULL,&startup,&pInfo); // PROCESS_INFORMATION
WaitForSingleObject(pInfo.hProcess,INFINITE);
//check for the hint here
//if (completed) call ur message
//this is the raw way of doing it.
MessageBox("Click YES to Configure EncryptaKey VPN 2","EncryptaKey VPN",MB_YESNO|MB_ICONQUESTION);
|
|
|
|
|
i dont know how to confirm that the process is completed since the process is to install a package
Arise Awake Stop Not Till ur Goal is Reached.
|
|
|
|
|
deeps_cute wrote: i am calling a exe file from my program which in turn calling an batch. after executing this exe compltely only, i have to open a message box. but this is posting while the batch fle is opened.
It sounds like the problem is the other exe is not waiting on the batch file? So if your program is waiting on the exe (which is not waiting on the batch file), your program is also not waiting on the batch file? Can you confirm this (e.g., run calc.exe and see if your program waits for it)?
deeps_cute wrote: startup.hStdInput=NULL;
Since you've already called ZeroMemory() , this statement is pointless.
deeps_cute wrote: CreateProcess(NULL,ovpncheck1.GetBuffer(ovpncheck1.GetLength() + 1)...
Why are you calling GetBuffer() ? It is not necessary.
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
PROCESS_INFORMATION prcInfo;
STARTUPINFO startupInfo;
memset(&prcInfo, 0, sizeof(PROCESS_INFORMATION) );
memset(&startupInfo, 0, sizeof(STARTUPINFO ) );
startupInfo.cb = sizeof (STARTUPINFO );
//DEBUG_ONLY_THIS_PROCESS
BOOL blnStatus = CreateProcess("e:\\temp\\samp.bat", NULL, //CreateProcess("c:\\winnt\\system32\\calc.exe", NULL,
NULL,
NULL,
FALSE,
0,
NULL,
NULL,
&startupInfo,
&prcInfo);
if (blnStatus )
{
STILL_ACTIVE
DWORD dwExitCode=0;
BOOL blnExit = GetExitCodeProcess(prcInfo.hProcess, &dwExitCode);
WaitForSingleObject(prcInfo.hProcess, INFINITE);
blnExit = GetExitCodeProcess(prcInfo.hProcess, &dwExitCode);
dwExitCode=0;
AfxMessageBox("Hello Fin",MB_OK);
CloseHandle(prcInfo.hProcess);
//This is the code that i had tested working fine for me.
// i tested in both the case in which the first one i called
//the executable file directly, in the second time i called
//using a batch file. The next statement of WaitForSingleObject is watiting actuall to end its process.
|
|
|
|
|
I working with print.
I want print preview multipage.
Please help me.
|
|
|
|