|
Hi,
On creating registry key, a string value named "(Default)" is automatically generated, whose data is "value not set" means no value, how can I assign some data to that value programmatically.
Best Regards,
Mushq
Mushtaque Ahmed Nizamani
Software Engineer
Ultimus Pakistan
"English is my second language; please excuse any grammatical or spelling mistakes"
|
|
|
|
|
Mushq wrote: how can I assign some data to that value programmatically.
By using RegSetValue(hKey, "", ...) .
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
David, Thanks a lot
Best Regards,
Mushq
Mushtaque Ahmed Nizamani
Software Engineer
Ultimus Pakistan
"English is my second language; please excuse any grammatical or spelling mistakes"
|
|
|
|
|
Hey I'm trying to use the Accessible Object API to find out when an event happens in an IM window, I've got some visual basic code for it but when i try to do this in a console applications it doesn't work. I know its probably something to do with the infinite for loop but i have no idea how else to do this and wait for some events to be printed into the console, heres the code i mainly got from msdn.
<br />
HWINEVENTHOOK g_hook;<br />
<br />
void CALLBACK HandleWinEvent(HWINEVENTHOOK hook, DWORD event, HWND hwnd,<br />
LONG idObject, LONG idChild,<br />
DWORD dwEventThread, DWORD dwmsEventTime)<br />
{<br />
printf("called\n");<br />
IAccessible *pAcc = NULL;<br />
VARIANT varChild;<br />
HRESULT hr = AccessibleObjectFromEvent(hwnd, idObject, idChild, &pAcc, &varChild); <br />
if ((hr == S_OK) && (pAcc != NULL))<br />
{<br />
char *classname;<br />
classname = (char*)malloc(15);<br />
GetClassName(GetParent(hwnd),(LPTSTR)classname,14);<br />
printf("Classname: %s\n", classname);<br />
if(strcmp(classname,"IMWindowClass") == 0){<br />
printf("found\n");<br />
}<br />
<br />
}<br />
}<br />
<br />
void InitializeMSAA()<br />
{<br />
CoInitialize(NULL);<br />
g_hook = SetWinEventHook(<br />
EVENT_SYSTEM_ALERT , EVENT_OBJECT_ACCELERATORCHANGE,
NULL,
HandleWinEvent,
0, 0,
WINEVENT_SKIPOWNPROCESS);
}<br />
<br />
int main(array<System:(Smilie)tring ^> ^args)<br />
{<br />
InitializeMSAA();<br />
printf("init'd\n");<br />
while(1);<br />
system("pause");<br />
return 0;<br />
}<br />
Any help would be great!
|
|
|
|
|
I am using TextOut() fun but it's taking Black as a default colour
can anybody tell me how to change it's colour????
Thanks!!!
There Is Nothing Right & Wrong
|
|
|
|
|
Use of SetTextColor for text color and SetBkcolor for background color.
|
|
|
|
|
Hello every1,
I m trying to develope an application in MFC which deletes all Internet cookies .I am using Firefox. Can u plz suggest me how can I do that?
Plz reply me as soon as possible.
Thanks.
s_v_patel
|
|
|
|
|
|
tht's fine for IE ..but that is not gonna work for FireFox... want some functions in MFC which actually retrives cookies stored on my machine n delete them.
Thanks.
s_v_patel
|
|
|
|
|
Where are those cookies stored? This is not a rhetorical question. You just might have to search the HD to find them. But without that information, deleting said files won't be possible.
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Of course those cookies r stored on my machine. I want a fuction in MFC which retrieves internet cookies and delete them.
I have mane application for Internet explorer but not for FireFox..
Thanks.
s_v_patel
|
|
|
|
|
s_v_patel wrote: I want a fuction in MFC which retrieves internet cookies and delete them.
Such a function does not exist. You will need to create your own.
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
tht's wat i m asking for..that how may i create that..cuz there is no way i can access it using MFC...(spent entire day searching)..lol...
Cud u plz tell me how may i develope it?
|
|
|
|
|
Firefox stores your cookies in the automatically generated file cookies.txt under your specific Profile folder. Just delete the cookies.txt file from that folder.
char szPath[MAX_PATH];
SHGetFolderPath(NULL, CSIDL_APPDATA, NULL, SHGFP_TYPE_CURRENT, szPath);
PathAppend(szPath, "Mozilla\\cookies.txt"); At this point, verify that szPath contains the correct value.
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
i have a program (which i didn't create) that have a built in timer.
the timer count backwards and i want to prevent the timer from hitting zero.
i tried compiling this c program:
<pre>
#include "stdafx.h"
#include <time.h>
#include <conio.h>
#include <stdio.h>
#include <stdlib.h>
#include <windows.h>
size_t main( int argc, char *argv[] )
{
SYSTEMTIME time;
GetSystemTime(&time);
while(!kbhit())
SetSystemTime(&time);
if(!getch())
getch();
return 0;
}
</pre>
and its stopping the windows (win xp sp2) clock but not the program timer, do anyone have a suggestion how to make the timer stop counting back?
thanks to anyone who actually read the post
|
|
|
|
|
shja88 wrote: ...but not the program timer...
Which is what?
More importantly, just what exactly are you trying to accomplish?
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
sorry i didn't understand the question, can you rephrase that?
my english skills isn't that good
|
|
|
|
|
You've got a program containing a timer. That timer counts backwards.
Now you run another program that resets the Windows time as fast as it can.
And you are astonished that the first program still counts backwards?
Though I speak with the tongues of men and of angels, and have not money, I am become as a sounding brass, or a tinkling cymbal. George Orwell, "Keep the Aspidistra Flying", Opening words
|
|
|
|
|
yep.
are you saying that the timer is getting his updates not from the windows clock?
if so then from what clock does it updates? (bios????)
|
|
|
|
|
shja88 wrote: are you saying that the timer is getting his updates not from the windows clock?
Surely not. Especially if it just counts some numbers backwards, and not a time.
There are a plethora of different timers in Windows:
SetTimer and WM_TIMER are the most basic ones.
But there are High-ResolutionTimers and MultimediaTimers...
You definitly need to read the MSDN Topic "About Timers".
Hacking a shareware program?
Though I speak with the tongues of men and of angels, and have not money, I am become as a sounding brass, or a tinkling cymbal. George Orwell, "Keep the Aspidistra Flying", Opening words
|
|
|
|
|
jhwurmbach wrote: Hacking a shareware program?
actually not, its something far more simpler then that.
BTW you have any idea if i can actually change the timer?
and thanks for all your help, ill go check msdn.
thank you very much
|
|
|
|
|
shja88 wrote: you have any idea if i can actually change the timer?
When the application is using SetTimer / WM_TIMER, you could try sending WM_TIMER messages to the application window.
See is this speeds up the timer.
On of the gaping security holes in windows design: Anyone can send any message to anyone. (See also WM_COPYDATA).
Though I speak with the tongues of men and of angels, and have not money, I am become as a sounding brass, or a tinkling cymbal. George Orwell, "Keep the Aspidistra Flying", Opening words
|
|
|
|
|
thank you very much, you helped me a lot
|
|
|
|
|
Hi,
I have created a property sheet and set the wizard mode for that, then added a property page to that sheet, When i execute that i see property page embeded in property sheet and plus some more space(which is not part of dialog) at the border, how can i remove that space.
Best Regards,
Mushq
Mushtaque Ahmed Nizamani
Software Engineer
Ultimus Pakistan
"English is my second language; please excuse any grammatical or spelling mistakes"
|
|
|
|
|
The wizard as also Propertysheets are using the size of biggest sheet. Check this out.
If this wont help you it is best to think about writing the wizard with multiple dialogs.
Greetings from Germany
|
|
|
|