|
does anybody know about libraries to use OCR?, if they are free better, thanx
|
|
|
|
|
If you right mouse click in on any of the column in Windows Explorer (NOT IE), you can add or remove columns, like file size, date, attribs, etc. Any way to add your own column?
Thanks
Ralph Krausse
|
|
|
|
|
|
Please also tell me how can change the caption text at run time. Please give me the code.
Thankyou
|
|
|
|
|
pWnd->SetWindowText("MyNewCaption");
Cheap Oil. It's worth it!
|
|
|
|
|
SetWindowText()
Renjith True CP ian
|
|
|
|
|
I create an control using CreateWindow. The class name is edit. Then I set a procedure for it by using SetWindowLong fn GWL_WNDPROC. Even though, control goes there, its normal operations are affected. I clearly called DefWindowProc for message i dont want to handle. Then what is the right procedure, Pl. reply me.
|
|
|
|
|
I guess you must retrieve the previous window proc with GetWindowLong and GWL_WNDPROC and use this as your default proc instead of DefWindowProc .
Joaquín M López Muñoz
Telefónica, Investigación y Desarrollo
|
|
|
|
|
What you need to do is when you call SetWindowLong, save the old WindowProc that is returned from that window.
Then if you do not want to handle that message you need to call the window proc that you cached. But you cannot call it directly, you will need to call CallWindowProc with the previous window proc as a parameter. CallWindowProc shields you from the possibility that you are dealing with a UNICODE window when you have create an ansi version. Windows automatically thunks all of the parameters for you.
CAlling DefWindowProc is not the answer because this is the default window procedure for all windows. There is very little processing that is done in DefWindowProc.
Build a man a fire, and he will be warm for a day Light a man on fire, and he will be warm for the rest of his life!
|
|
|
|
|
What is the data type I can use to identify a variable that is 8 bytes. I get a warning that states my data will be truncated because I didnt allocate enough memory. I have used long, double, long double, but nothing works. I am setting a variable equal to a hex value.
double long rhs = 0xBFF074003BA3D70A;
This is how I have assigned my variable. Can I get some help on this. Thank you.
Josh
|
|
|
|
|
Heya,
try LONGLONG or __int64
/WW
|
|
|
|
|
__int64 for a signed number, or unsigned __int64 for unsigned.
--Mike--
Just released - RightClick-Encrypt - Adds fast & easy file encryption to Explorer
Like the Google toolbar? Then check out UltraBar, with more features & customizable search engines!
My really out-of-date homepage
Sonork-100.19012 Acid_Helm
|
|
|
|
|
I put an OCX control window. I put an Edit box derived from CEDit. In Edit box, if I press backspace, message will not posted to my active edit box, instead goes to IE. Similarly, Arrow Keys, Home, End Messages are captured by IE. How this can be avoided? How I Edit smoothly?
|
|
|
|
|
Please give me the code of edge detection.
It will be so nice of you.
Thanks
|
|
|
|
|
did you try searching codeproject? did you try google?
-c
Cheap Oil. It's worth it!
|
|
|
|
|
one method to detect edge:
do convolution on your image, and you'll get the edge.
Search for "image processing" and you'll get the algorithm.
|
|
|
|
|
Knowledge Seeker wrote:
Knowledge Seeker
You're not seeking very hard. Search the site.
Christian
I am completely intolerant of stupidity. Stupidity is, of course, anything that doesn't conform to my way of thinking. - Jamie Hale - 29/05/2002
Half the reason people switch away from VB is to find out what actually goes on.. and then like me they find out that they weren't quite as good as they thought - they've been nannied. - Alex, 13 June 2002
|
|
|
|
|
I've got an application to develop and am just modifying the MTTTY sample from MSDN for now. I've got to be able to record data to disk at 115K. I've got several questions and considerations.
1) I am assembling 8 and/or 14 byte messages that must be time stamped somewhat accurately but at a 10th of a second time resolution. Thus, I don't want a large buffer since many msgs may be in it and they would probably receive the same time stamp.
2) The time stamp and one other attribute has to be added to the 8 or 14 byte msgs and all msgs written to disk are 20 bytes in length so the msgs are padded if necessary. I've already thought that data will be written in 2K blocks or 200 msgs at a time to disk.
3) The read thread from mttty sample has it's ReadFile function in overlapped mode, has a 512 byte buffer, and uses WaitForMultipleObjects with a 500 ms timeout. The WaitForMultipleObjects looks for a GetOverlappedResult() from the ReadFile() where it may have data. I'm thinking and I'm not sure but after the 500 ms timeout is when all processing is allowed and that's when I would be able to parse the data read and add my timestamp and even write the data to disk.
4) At 115K baud a character is received in about 87 usecs and an entire msg would take about 720 usecs to 1.2 msecs. I'm thinking my buffer should be alot smaller perhaps maybe about 6 bytes (so I don't have same timestamp for each msg even if it was less than 500 ms delay in between) which means I'll have to lower the timeout too. What would be a decent value for the timeout? I'm thinking 5 msecs.
5) Would there be enough time to process the msgs and write the data to disk in the same thread or should there be a separate thread to write the data to disk?
Does any of this make sense? Any suggestions?
|
|
|
|
|
You can setup the thread that does the reads to return immediately when a call to ReadFile is done. You can also get the number of bytes read from the buffer from the call. I do this for a serial application, and build up any messages etc in a local buffer. You can then Sleep() your thread if no data is comming in in 1ms intervals.
COMMTIMEOUTS timeouts ;
timeouts.ReadIntervalTimeout = MAXDWORD ;
timeouts.ReadTotalTimeoutConstant = 0 ;
timeouts.ReadTotalTimeoutMultiplier = 0 ;
timeouts.WriteTotalTimeoutConstant = 0 ;
timeouts.WriteTotalTimeoutMultiplier = 0 ;
SetCommTimeouts(m_hSerialPort, &timeouts) ;
...
while (TRUE)
{
if (!ReadFile(m_hSerialPort, buffer, 1, &dwNumBytesRead, NULL))
{
int error = GetLastError() ;
TRACE("Serial port read fail, error %1d\n", error) ;
}
if (dwNumBytesRead == 0)
{
Sleep(1) ;
continue ;
}
}
Roger Allen
Sonork 100.10016
If I had a quote, it would be a very good one.
|
|
|
|
|
What about a separate thread for writing the msgs to disk? Do you think I need that? Also, is it best to do a memcpy of whatever data you received from ReadFile's buffer to another buffer or is the data not written to that buffer until you call ReadFile()? I'm wondering if the data in the buffer could be corrupted in between calls to ReadFile() especially in the overlapped situation.
|
|
|
|
|
Here's a problem for the shell gurus:
I'm writing a namespace extension which primary purpose is to take over certain folders and display their content in a different way. I do not know beforehand what folders my NSE should handle so each folder it should handle will get a hidden desktop.ini file with the appropriate entries:
[.ShellClassInfo]
CLSID={33F9BE31-5B67-4fb6-AE60-CEF29F193045}
These special folders should get a custom icon. This is accomplished through some registry magic: "HKEY_CLASSES_ROOT\CLSID\{33F9BE31-5B67-4fb6-AE60-CEF29F193045}\DefaultIcon" will get a default string value that contains the path to my NS followed by the ID of the icon that should be displayed for these folder.
And this works both under Win98, WinNT and Win2000. However, under WinXP it doesn't. I've tried to fix that by adding these lines to the desktop.ini file:
IconFile=<path to my NS>
IconIndex=<index of my icon>
but no luck. I also tried to specify in the registry settings the path to shell32.dll and an ID of some icon that I know that works but no luck either.
Does anyone have a solution to this problem? Or is perhaps noone creating namespace extensions using this technique?
With best regards,
Daniel
|
|
|
|
|
There is a setting in the control panel -> Power Options-> Power schemes tab, for setting Stanby and Hibernate time. i.e. after what unit of time the system should go into stand-by state and similar combo box is also present for hibernate state.
I have tried to use the API GetCurrentPowerPolicies(). In this a structure is filled for POWER_POLICY->MACHINE_POWER_POLICY. In that accoding to MSDN values for stand-by and hibernate should get filled , but it does not.
I am getting the time for disk spindown and video time out and also the Poer Scheme, but I am not getting the standy-by and hibernate time.
Can anyone of you tell me how to obtain the standby and hibernate time.
|
|
|
|
|
I'm trying to get VC6 to use the Windows Debug Symbols, but VC6 does not load them from the installed location (c:\windows\Symbols\...).
I have setup the _NT_SYMBOL_PATH to point to the proper dir.
I have tried putting some directories in the PATH: c:\windows;c:\windows\Symbols;c:\windows\Symbols\Dll.
Neither is successfull with VC6 (But WndDbg is loading symbols alright).
OTOH when I copy the .PDB to the same directory as the DLL they match VC6 happily loads them symbols.
What's going on?
Is there some setting in the VC6 environment that I should have made?
If it matters then I am on WinXP, with VC6 SP5 applied.
MBHansen
|
|
|
|
|
VC6 loads only .dbg file from _NT_SYMBOL_PATH not .pdb. There was a kb article about it.
|
|
|
|
|
Does this mean that there is no way that VC6 will find .pdb files for for example kernel32.dll, EXCEPT if the kernel32.PDB is placed in the same directory as kernel32.dll?
Do you have some info about the KB article? I tried searching for variations over the following words: VC6 VC PDB DBG _NT_SYMBOL_PATH...
MBH
|
|
|
|