|
hi all
i know that the bitmap are saved in hard disk in reverse format
(opposite to the displayed format).i had shown it on the picturebox and got the hbitmap handler will the handler be in reverse order or normal as displayed on the picturebox.
ddd
-- modified at 4:48 Friday 17th March, 2006
|
|
|
|
|
tasleem143 wrote: got the hbitmap handler will the handler be in reverse order or normal as displayed on the picturebox.
it format is same as displayed on picture box.. have a try man
|
|
|
|
|
thanks i tried it is same as displayed on the picturebox not reversed.
ddd
|
|
|
|
|
Porting an MFC app from VS6 to VS2005 gives a CTime problem:
we have binary historic files in which CTime is stored as 4 bytes, in VS2005 CTime is 8 bytes.
I need to convert a 64bit CTime to 32bit CTime and vice versa.
OR i need a 32bit CTime object.
I now get errors like 'cannot convert from ATL::CTime to __time32_t or long etc.
Ronald
|
|
|
|
|
I have to write a module in VC++ 6.0 that will do the foll:-
Launch Icons from the system tray and log the pass or fail result.
Kindly suggest me how i need to go ahead to enumerate all icons present in the System Tray and launch each of them, one after the other.
launching may be in amy order.
A reply at the earliest will be very helpful as i need to finish this within 4 days.
Thanks in advance.
Sincerely
Giftsana
|
|
|
|
|
|
Thanks for the response.
I went to that site earlier and customized it as per my module specs.
It works!
This is a good sample and i appreciate the samples in codeproject as they are very helpful.
Thanks
Giftsana
|
|
|
|
|
Please view the message here!My trouble here[^]
Tomorrow may not exciting, but the exciting tomorrow certainly will come.
|
|
|
|
|
why don't you ask it in the article message board (at the bottom of the article) ?
|
|
|
|
|
Hello everybody,
For my project I need to record some data from the wave audio inut device.
To do this I have created a class CWaveIn wich simply encapsulate the standard windows calls waveInOpen() waveInClose() waveInAddBuffer() etc...
When I open the wave audio input device I use the WAVE_MAPPER flag. I use a dedicated thread to process the driver messages. I only process the WIM_DATA driver messages. The dedicated thread calls a user defined callback function to store the signal to disk and do some computations on the data. These computations are CPU expensive so it is possible that at some point in time there are more than one WIM_DATA messages on the message queue of the dedicated thread.
In my project I need to mark the first and the last waveheader in a serie of waveheaders with a start and stop time respectivly. Oke to mark the first waveheader is easy just simply set a flag when the user presses the start button and clear the flag in the callback function. But to mark the last waveheader is a lot more complicated. I use the waveInGetPosition() function directly after the user stopped the wave audio input device. (All waveheaders are of the same size) Devide this number by the size of the waveheaders and voila you have got the last waveheader. (Since recording started)
Oke this works perfectly for large waveheaders. (0.1 seconds and bigger) But when I use small waveheaders I lose one WIM_DATA message in a series of WIM_DATA messages? The current position (waveinGetPosition) is one wavheader ahead of the number of waveheaders I ve received from the device driver.
Thank you
|
|
|
|
|
Hi Dear,
I am building my application in visual studio 6.0 however I am getting the following error. Can you please help me resolve this.
BSCMAKE: error BK1503 : cannot write to file 'TouchDbg/test.bsc'
Thanks
-- modified at 2:38 Friday 17th March, 2006
|
|
|
|
|
Close and start again. Or click on clean.
Nibu thomas
Software Developer
|
|
|
|
|
I have tried to clean and than rebuild all however error is still coming.
|
|
|
|
|
Close VS and delete the bsc file.
Nibu thomas
Software Developer
|
|
|
|
|
Hi,
I am receiving 60 BYTE type data to the serial port from an external device.
I want to convert the 2 consequent received bytes each to a 16 bit word and store it in excel file?
Does anyone have Idea , how to do this?
For example,
i received 60,25 consequently to the serial port. Now i have to store 6025 in the Excel sheet.
Thanks,
Please help me out to solve this problem.
Chetan.
Helping others satisfies you...
|
|
|
|
|
Like this? (It's one way to do it, there are other ways as well)
unsigned char serialBuffer[x];
// Assume serialBuffer contains two chars with "ASCII" value 60 and 25 (decimal).
unsigned int word = (((unsigned int) serialBuffer[0]) * 100) + (unsigned int) serialBuffer[1];
// Now word is 6025.
// if you want a char[]
char chValue[10];
itoa(word, chValue, 10);
// Now, chValue contains "6025"
|
|
|
|
|
I assume that by 60 and 25, you mean the hex values 0x3c and 0x19.
If the byte stream arriving is ordered as 0x3c, 0x19, ..., and you want to interpret that as 0x3c19, then you have a big endian stream:
typedef unsigned char byte;
typedef unsigned short word;
const byte low = 0x19;
const byte high = 0x3c;
const word merged = (word(high) << 8) | low; However, since you want to store it as 6025 in Excel, I assume that you by that mean the string "6025". Otherwise you need to state your need better. To get "6025", you can do this:
const char buffer[33];
const std::string left(_itoa_s(high, buffer, 33, 10));
const std::string right(_itoa_s(low, buffer, 33, 10));
const std::string merged(left + right); Note: this of course come without warranties, it's the concept that's important here.
--
The Blog: Bits and Pieces
|
|
|
|
|
Hello
Can i hide all my desktop icons, wallpapers, taskbar etc using c++. Actually i want to clear my desktop.
Thank you.
We Believe in Excellence
www.aqueelmirza.cjb.net
|
|
|
|
|
static HWND hprg = ::FindWindow(_T("Progman"), NULL);
static BOOL doShow = FALSE;
if(hprg!=NULL)
::ShowWindow(hprg, (doShow==TRUE?SW_SHOWNORMAL:SW_HIDE));
static HWND hshell = ::FindWindow(_T("Shell_TrayWnd"), NULL);
if(hshell != NULL)
::ShowWindow(hshell, (doShow==TRUE?SW_SHOWNORMAL:SW_HIDE));
doShow = !doShow;
But the problem with this is if you press window key + D (Shortcut for show desktop), then it displays all the desktop icons(Provided your application is not in focus.) but it works fine with taskbar.
Do remember to set these settings back to normal once the application exits.
Nibu thomas
Software Developer
|
|
|
|
|
Thank you Nibu! it works perfectly.
We Believe in Excellence
www.aqueelmirza.cjb.net
|
|
|
|
|
Aqueel wrote: Can i hide all my desktop icons, wallpapers, taskbar etc using c++. Actually i want to clear my desktop.
i am little confused your want to hide all item from your desktop or delete all icon from desktop!..
if you want to hide all item from the desktop you can try Nibu's method.. or create a your desktop using CreateDesktop api
|
|
|
|
|
No i just wanted to hide them. So Nibu's method works perfectly.
Thank you.
We Believe in Excellence
www.aqueelmirza.cjb.net
|
|
|
|
|
Hello
i am working with c++.I want to ask if i can calculate time to execute some intructions. Actually i want to check how much time a piece of code is taking to execute.
Thank you.
We Believe in Excellence
www.aqueelmirza.cjb.net
|
|
|
|
|
use profile in the VC++.
Simply if u want to know the time taken for some statements put OutputDebugString()in the before and end afetr the stement. Now using Debug viewer u can see the time taken
nave
|
|
|
|
|
Aqueel wrote: Actually i want to check how much time a piece of code is taking to execute.
try profiler or GetTickCount api!
|
|
|
|