|
If I can find the word breaks of the string on the rich edit control until the end of it, i can found the number of words.
I appreciate your help all the time...
Eranga
|
|
|
|
|
Have you tried to count the number of "blank spaces"? That number + 1 should be the number of words.
Greetings.
--------
M.D.V.
If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about?
Help me to understand what I'm saying, and I'll explain it better to you
“The First Rule of Program Optimization: Don't do it. The Second Rule of Program Optimization (for experts only!): Don't do it yet.” - Michael A. Jackson
|
|
|
|
|
Hi! I'm Rathakrishnan. I've a project developed in VC++. It was compiled and run very well. Once I rebuilt the the solution, it showed me an error
which said "Error Spawning rc.exe". I didn't do any thing(not changed any code or didn't even open the resource file at all). How do I resolve this error?
|
|
|
|
|
|
try the following.
in msdev take tools->options->directories.
in the "show directories" combobox, select executable files. Now in the below list box, add the path of folder where CL.exe exisits( usually in the "C:\Program Files\Microsoft Visual Studio\VC98\BIN" ). Click ok and compile again
|
|
|
|
|
I've included "C:\Program Files\Microsoft Visual Studio\VC98\BIN" in the executable files. Now also the same problem persists. What to do?
|
|
|
|
|
does the cl.exe exits in the "C:\Program Files\Microsoft Visual Studio\VC98\BIN" folder?
|
|
|
|
|
Yes. CL.exe exists in the "C:\Program Files\Microsoft Visual Studio\VC98\BIN" folder. I searched and added the path. Any alternatives?
|
|
|
|
|
sorry. I though it was cl.exe The rc.exe exists in the folder
"C:\Program Files\Microsoft Visual Studio\Common\MSDev98\Bin". add that folder too
|
|
|
|
|
I could not find the file rc.exe. In case Visual Studio .NET 2003, where the file exists usually?
|
|
|
|
|
T.RATHA KRISHNAN wrote: In case Visual Studio .NET 2003, where the file exists usually?
C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\bin
C:\Program Files\Microsoft Visual Studio .NET 2003\Common7\Tools\Bin
|
|
|
|
|
Hi! Only a dll file called rcdll.dll is present in both the locations. Shall I add this dll file? If yes, where should I add?(whether in the source files or Include files).
|
|
|
|
|
T.RATHA KRISHNAN wrote: Hi! Only a dll file called rcdll.dll is present in both the locations
ho ho... . So that file some how might have got deleted. Better reinstall vs or copy those files from some other machine.
|
|
|
|
|
The following code gives me the error:'IWebBrowser2' : illegal use of this type as an expression but if I comment out the first line //TRACE("DocumentComplete"); then there is no error. I am lost I don't know why this is happening.
void DocumentComplete(IDispatch *pDisp, VARIANT *URL)
{
TRACE("DocumentComplete");
IWebBrowser2* wb = 0;
}
I am using win32 application.
Any idea will be helpful.
Thank you.
|
|
|
|
|
What is the definition of TRACE ?
Perhaps this will help (guess):
TRACE(_T("DocumentComplete");
Steve
|
|
|
|
|
I use vs2005,
In the afxdlgs.h file, I can see the declaration of CFontDialog constructor's code, but i can't find the implementation code,
Does anybody know where to find the code?
Or microsoft didn't offer the code at all?
|
|
|
|
|
the implementation of the CFont can be found in the file. "Microsoft Visual Studio 8\VC\atlmfc\src\mfc\dlgfnt.cpp".
You can find the source code by user self using the follwoing technique. Suppose you have written code like
CFontDialog Dlg;
put a break point in this line and when the break point hits while running, press F11( step in ) so that the controls go to the constructor of the CFontDialog.
|
|
|
|
|
Hi all,
I'm wondering is there an API that could be used to test for whether a thread has ended(signaled in other words). WaitForSingleObject is blocking wait for the thread to signaled, but I want nonblocking wait.
Thanks,
|
|
|
|
|
reading the documentation on WaitForSingleObject would not be a waste of time.
|
|
|
|
|
Yeah, you're right, I should have read it with more attention. My bad!
IGNORE(#define IGNORE 0) should be used instead of INFINITE.
Thanks!
|
|
|
|
|
You can use the GetExitCodeThread() function. If the thread has not ended, the the termination status returned is STILL_ACTIVE.
|
|
|
|
|
Thanks! I think that works too!
|
|
|
|
|
From MSDN:
Therefore, an application should not use STILL_ACTIVE (259) as an error code. If a thread happens to return STILL_ACTIVE (259) as an error code, applications that test for this value could interpret it to mean that the thread is still running and continue to test for the completion of the thread after the thread has terminated, which could put the application into an infinite loop.
It's best to avoid GetExitCodeThread for this purpose (checking if a thread has finished) IMHO.
Steve
|
|
|
|
|
I have developed an application using MFC. It has been brought to my attention that when the application is opened repeatedly, the FormView screen gradually moves across and down the screen. How do I fix the position of the FormView display?
|
|
|
|
|
In the application's main window class, add a handler for WM_CREATE.
In OnCreate(), you can use MoveWindow() to resize/reposition the window
the way you want it. You could store the size and position in the registry
or some other place so the window always opens the way the user last left it.
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|