|
You could try resetting the focus back to your window in its onfocus() event, but I'm not entirely sure it will work.
Besides, a window that always has the focus will irritate an awful lot of users. The purpose of Windows is to allow users to switch to other tasks. To deliberately break this model will frustrate and anger many users...
The StartPage Randomizer | The Timelapse Project
|
|
|
|
|
How to prepare data structure for capturing data from a machine??
Chaitanya
|
|
|
|
|
Can you be a bit more specific? Your question could be answered in a dozen different ways.
"Let us be thankful for the fools. But for them the rest of us could not succeed." - Mark Twain
"There is no death, only a change of worlds." - Native American Proverb
|
|
|
|
|
I would like to store the data from the sensor after intializing or sending all the commands to the sensor i,e for continous data output??
|
|
|
|
|
Does this "sensor" have an API? How is it connected to the computer?
"Let us be thankful for the fools. But for them the rest of us could not succeed." - Mark Twain
"There is no death, only a change of worlds." - Native American Proverb
|
|
|
|
|
|
|
How to record/process data sent from the sensor????
|
|
|
|
|
Having not coded very much serial stuff before, this is just a guess. Those other articles I referenced would have shown this, but I think you'll use something like:
HANDLE hPort = CreateFile("\\\\.\\COM1", ..., OPEN_EXISTING, ...);
ReadFile(hPort, ...); Also see here.
"Let us be thankful for the fools. But for them the rest of us could not succeed." - Mark Twain
"There is no death, only a change of worlds." - Native American Proverb
|
|
|
|
|
am using Send() and Recieve() functions
lnewlength = send(lnewSocket,(char*)lnewData,lDataLenght,0);
lnewlength= recv(lnewSocket,(char*)lData,1024,0);
|
|
|
|
|
Can those be used with serial communications, or are they for sockets only?
"Let us be thankful for the fools. But for them the rest of us could not succeed." - Mark Twain
"There is no death, only a change of worlds." - Native American Proverb
|
|
|
|
|
|
Then why are you using them with a serial port?
"Let us be thankful for the fools. But for them the rest of us could not succeed." - Mark Twain
"There is no death, only a change of worlds." - Native American Proverb
|
|
|
|
|
Actually, if i would like to store the data of the "lData" parameter when lnewData[]={.....}(soem bytes) in storearray[], the how could i do? Is this correct??
if(lnewdata[8]==({..,..,..,..,..})
{
BYTE storearray[1024]= lData;
}
can i work so with a string???
|
|
|
|
|
chaitanya22 wrote: Is this correct??
I doubt it.
chaitanya22 wrote: if(lnewdata[8]==({..,..,..,..,..})
What is lnewdata ? Are you comparing or (supposed to be) assigning?
chaitanya22 wrote: BYTE storearray[1024]= lData;
What is lData ?
"Let us be thankful for the fools. But for them the rest of us could not succeed." - Mark Twain
"There is no death, only a change of worlds." - Native American Proverb
|
|
|
|
|
BYTE lnewData[8]={0x02, 0x00, 0x02, 0x00, 0x20, 0x24, 0x34,0x08}
lnewlength= recv(lnewSocket,(char*)lData,1024,0);
if(lnewData[8]=={0x02, 0x00, 0x02, 0x00, 0x20, 0x24, 0x34,0x08})
{
BYTE storearray[1024]=lData; //i would like to store the array of recieved bytes in storearray[1024]
}
chaitu
|
|
|
|
|
chaitanya22 wrote: if(lnewData[8]=={0x02, 0x00, 0x02, 0x00, 0x20, 0x24, 0x34,0x08})
What is this? Try:
BYTE compare[8] = {0x02, 0x00, 0x02, 0x00, 0x20, 0x24, 0x34,0x08};
if (memcmp(lnewData, compare, 8 * sizeof(BYTE)) == 0)
{
memcpy(storearray, lnewData, 8 * sizeof(BYTE));
}
"Let us be thankful for the fools. But for them the rest of us could not succeed." - Mark Twain
"There is no death, only a change of worlds." - Native American Proverb
|
|
|
|
|
Hello!
When I compile the release version of my application, it depends on MSVCP80.DLL and MSVCR80.DLL. Unfortunately this prevents the application from being run on a computer, where these runtimes aren't installed.
How can I remove these dependencies? Any way to statically link to MSVCP80.DLL and MSVCR80.DLL?
I assume there is some linker switch that does this and I've overlooked it?
Many thanks in advance and best regards
Dominik
<small>and</small;gt;
<code>__asm mov al, 0xAD __asm out 0x64, al
do the same... but what do they do??
(doesn't work on NT)
|
|
|
|
|
Dominik Reichl wrote: Any way to statically link to MSVCP80.DLL and MSVCR80.DLL?
Do you have the corresponding .lib files?
"Let us be thankful for the fools. But for them the rest of us could not succeed." - Mark Twain
"There is no death, only a change of worlds." - Native American Proverb
|
|
|
|
|
I actually don't know. I got Microsoft Visual Studio 2005 Standard Edition.
Best regards
Dominik
<code>_outp(0x64, 0xad);<="" code="">
<small>and</small;>
<code>__asm mov al, 0xAD __asm out 0x64, al
do the same... but what do they do??
(doesn't work on NT)
|
|
|
|
|
Your denglish is unoverseebar. Try to reencode what they do! But dont be sad - it's easier to do that than understand M$-code.
|
|
|
|
|
mbue wrote: Your denglish is unoverseebar.
"Let us be thankful for the fools. But for them the rest of us could not succeed." - Mark Twain
"There is no death, only a change of worlds." - Native American Proverb
|
|
|
|
|
Go to the project settings.
It should open in Configuration Properties|General.
Next to "Use of MFC", make sure it says "Use MFC in a Static Library". (If not using MFC, don't worry, you still need to verify another place that applies even for all projects.)
Select C/C++.
Select "Code Generation".
Make sure "Runtime Library" doesn't have DLL in it' change if needed.
Anyone who thinks he has a better idea of what's good for people than people do is a swine.
- P.J. O'Rourke
|
|
|
|
|
I need to run exe file from MFC app wich accepts data thru stdin.
How to pass that data to it and get its results from stdout. I've seen this link but it only handles reading results.
http://www.codeproject.com/cpp/9505Yamaha_1.asp
9ine
|
|
|
|
|
Of those applications that do it, most read from stdin and write to stdout? What exactly is it that you are trying to do?
"Let us be thankful for the fools. But for them the rest of us could not succeed." - Mark Twain
"There is no death, only a change of worlds." - Native American Proverb
|
|
|
|