|
QueryPerformanceCounter and QueryPerformanceFrequency are used for extremely high frequency timing calculations. For his needs, it is a total over kill.
Pankaj
Without struggle, there is no progress
|
|
|
|
|
You guys are all great, but also which one should I use?
islam
|
|
|
|
|
Hi.
I load an icon with the function:
HICON hIcon=(HICON)LoadImage(NULL, "C:\\Icons\\Icon.ico", IMAGE_ICON, 0,0,LR_LOADFROMFILE | LR_DEFAULTSIZE);
How can I unload the icon?.
Thanks.
REMOVE AN ICON
|
|
|
|
|
when you're dealing with
bitmaps: DeleteObject();
cursors: DestroyCursor();
icons: DestroyIcon();
BOOL DestroyIcon(HICON hIcon);
returns TRUE if sucessfull.
i hope this helps...
|
|
|
|
|
HICON hIcon=(HICON)LoadImage(NULL, "C:\\Icons\\Icon.ico", IMAGE_ICON, 0,0,LR_LOADFROMFILE | LR_DEFAULTSIZE);
...
DestroyIcon(hIcon);
Dominik
_outp(0x64, 0xAD);
and
__asm mov al, 0xAD __asm out 0x64, al
do the same... but what do they do??
(doesn't work on NT)
|
|
|
|
|
Hi;
I was just wondering if anyone here knew how to caputre joystick/gamepade input when the program window isn't active (eg, sys tray)
I tried the joySetCapture function but that can only do 4 buttons.
I'd like to be able to get all input if possible.
thanks
Zhen
|
|
|
|
|
okay, i figured out that i can get all input by using the getJoyPosEx function.
But is there a way to know when a joystick event occurs?
Or do i just have to call this function on a timer?
Thanks
|
|
|
|
|
hi, have you tried WaitForSingleObject() & co.?
|
|
|
|
|
good idea but i don't have a handler to pass to it.
There is no joystick handle, atleast i don't think so, only a joystick id.
|
|
|
|
|
Once i used gflags.exe to enable heap monitoring, then when tried to restart the system its hanging before logging in to windows.
Is there any way to reset or disable the configuration set by gflag.exe
even in safe mode its not restarting.
|
|
|
|
|
Hello,
I wrote an application that creates several frames of images that I am saving them as PPM images now. I like to create an MPEG move based on them. What are my options? Is there any MPEG encoder for MSVC 6 that I can add to my application and directly creating MPEG movies? Note that I need a free library as this is not a commercialize application.
Best regards
|
|
|
|
|
Hello, I have an urgent need to be able to display a dialog from a console application and have all console application processing halted until the user selects a button from within the dialog. Also being able to tell which button was selected. Is this even possible?? I have had partial success with the display of the dialog. However, after the ShowWindow() call, the code continues. That will not work. I have also tried creating a thread and wait but that created a wait cursor and I could not select a buton in the dialog. I am back to square one. I had even thought about just creating a dialog app, but I need "the" app to accept command line args.
Any help or suggestions would be GREATLY appreciated. Thanks.
|
|
|
|
|
Do not use ShowWindow().
Create the dialog box (CDialog) on the heap (statically), then call it's DoModal member function to initialize a modal dialog box, assuming that you are using MFC to implement this. Program execution will halt until DoModal returns.
If you are not using MFC, then you need to manually lock the dialog resource and paint your window based on it's layout. This is MUCH more difficult and time-consuming, but if you do it once, remember to save a Win32 class hiearchy and post it here to CodeProject
Tip: Create a console application that supports MFC.
-Antti Keskinen
----------------------------------------------
The definition of impossible is strictly dependant
on what we think is possible.
|
|
|
|
|
Thank you very much. T:-Dhis works great!!
|
|
|
|
|
Just as an FYI.
A dialog app can indeed accept command line arguments. CWinApp has a data member named m_lpCmdLine that contains any command line parameters when the program starts up. You can access this through your InitInstance() method.
Here's a link on the MSDN site that talks about it.
|
|
|
|
|
Oh and just in case you ever decide down the road to develop a dialog based application that had command line support. Do a search at the top of this page under articles and use the phrase "command arguments". It will come up with a bunch of results for articles that have command line argument parsing (a couple of classes that people created too) to make it easier on the coding development.
|
|
|
|
|
Thanks for your replay on this. I will try this real soon and let you knwo how well it works. Thanks again. This forum is wonderful!!!!
|
|
|
|
|
|
I was develop an ocx control, my friend use it with visual foxpro.
It narmally run in win98, but slower and slower run in win2000.
|
|
|
|
|
SiddharthAtw wrote:
//Allocating strings
pszWndInfo = pClassName = pszName = (TCHAR *)malloc(255);
malloc is executed only ONCE and the pointers are all pointing to same memory location
and you are freeing the memory THREE times
have to crash
call malloc 3 times in three seperate lines for three seperate pointers
Hope it Helps
Live as if your were to die tomorrow. Learn as if you were to live forever.
-Mahatma Gandhi
|
|
|
|
|
It was crashing because of Illegal freeing(). Thanx for reply. BTW U are most active member rather problem solver. Great.I appreciate U effort
|
|
|
|
|
Hi!
Is there a way to use ON_UPDATE_COMMAND_UI for a CButton in my View. I newer get the message ON_UPDATE_COMMAND_UI.
MSc Bertil Morefält
|
|
|
|
|
As long as my memory serves me right there is no ON_UPDATE_COMMAND_UI handler for CButton
but if you wish to Disable or enable it
try
GetDlgItem(IDC_MYHANDY_BUTTON)->EnableWindow(FALSE);
or
m_btn.EnableWindow(FALSE);
Hope it Helps
Live as if your were to die tomorrow. Learn as if you were to live forever.
-Mahatma Gandhi
|
|
|
|
|
what msg are you trying to catch?
|
|
|
|
|
If i am not mistaken ON_UPDATE_COMMAND_UI macro is used in WTL/ATL
I Touched Osama Bin Ladens Bushy Beard
|
|
|
|